From 94e7d61719f630502c360b2e69a09528558391fe Mon Sep 17 00:00:00 2001 From: RasPhilCo Date: Thu, 11 Feb 2021 09:33:33 -0800 Subject: [PATCH] fix: determine current version helper (#212) --- src/commands/update.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/commands/update.ts b/src/commands/update.ts index 0aa9555d..ccd08176 100644 --- a/src/commands/update.ts +++ b/src/commands/update.ts @@ -180,7 +180,7 @@ export default class UpdateCommand extends Command { private async determineCurrentVersion(): Promise { try { - const currentVersion = await fs.readlink(path.join(this.clientRoot, 'current')) + const currentVersion = await fs.readFile(path.join(this.clientRoot, 'bin', this.config.bin), 'utf8') const matches = currentVersion.match(/\.\.[/|\\](.+)[/|\\]bin/) return matches ? matches[1] : this.config.version } catch (error) {