修复 command 变量

This commit is contained in:
whyour 2025-04-25 01:14:58 +08:00
parent 73ff23d315
commit b5e6bfd283

View File

@ -274,13 +274,13 @@ export default class DependenceService {
: DependenceStatus.removing; : DependenceStatus.removing;
await DependenceModel.update({ status }, { where: { id: depIds } }); await DependenceModel.update({ status }, { where: { id: depIds } });
let depRunCommand = isInstall let command = isInstall
? getInstallCommand(dependency.type, depName) ? getInstallCommand(dependency.type, depName)
: getUninstallCommand(dependency.type, depName); : getUninstallCommand(dependency.type, depName);
if (isLinuxDependence) { if (isLinuxDependence) {
depRunCommand = isInstall command = isInstall
? linuxCommand.install ? `${linuxCommand.install} ${depName.trim()}`
: linuxCommand.uninstall; : `${linuxCommand.uninstall} ${depName.trim()}`;
} }
const startTime = dayjs(); const startTime = dayjs();