pkg(*-*): Fix uninstall

This commit is contained in:
Dan Vargas 2021-04-10 16:48:33 -05:00
parent 81cdc766b6
commit d3ce08b170
3 changed files with 6 additions and 6 deletions

View file

@ -136,10 +136,10 @@ class Package {
logger.info(`Uninstalling ${this.language}-${this.version.raw}`);
logger.debug("Finding runtime")
const runtime = runtime.get_latest_runtime_matching_language_version(this.language, this.version.raw);
const found_runtime = runtime.get_latest_runtime_matching_language_version(this.language, this.version.raw);
logger.debug("Unregistering runtime")
runtime.unregister();
found_runtime.unregister();
logger.debug("Cleaning files from disk")
await fs.rmdir(this.install_path, {recursive: true})

View file

@ -91,7 +91,7 @@ module.exports = {
// DELETE /packages/:language/:version
async package_uninstall(req, res) {
logger.debug('Request to install package');
logger.debug('Request to uninstall package');
const pkg = await get_package(req.params.language, req.params.version);