diff --git a/src/effektManager.ts b/src/effektManager.ts index 29f0f5f..fede667 100644 --- a/src/effektManager.ts +++ b/src/effektManager.ts @@ -10,12 +10,12 @@ interface InstallationResult { success: boolean; executable?: string; message: string; - version?: string | null; + version?: string; } interface EffektExecutableInfo { path: string; - version: string | null; + version: string; } /** @@ -47,16 +47,12 @@ export class EffektManager { * * @returns a version number like '0.2.2' or '0.25.2.13' or '0.99.99+nightly.rev.abcdef', etc. */ - private async fetchEffektVersion(path: string): Promise { + private async fetchEffektVersion(path: string): Promise { /// Helper function to remove a generic prefix from a string const removePrefix = (value: string, prefix: string) => value.startsWith(prefix) ? value.slice(prefix.length) : value; const versionOutput = await this.execCommand(`"${path}" --version`); - if (versionOutput.trim() === '') { - return null; - } - // TODO: Handle outputs that don't start with the correct prefix? const version = removePrefix(versionOutput.trim(), "Effekt "); // NOTE: the space is important here return version;