diff --git a/package.json b/package.json index be3a7929..938badbf 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "explorook", - "version": "1.8.33", + "version": "1.8.34", "description": "Rookout's site addon to support local files and folders", "main": "dist/index.js", "scripts": { diff --git a/src/api.ts b/src/api.ts index dda63162..590d98bb 100644 --- a/src/api.ts +++ b/src/api.ts @@ -304,12 +304,12 @@ export const resolvers = { }, appVersion: async (parent: any): Promise => { if (process.env.development) { - return require("../package.json").version; + return require("../package.json")?.version; } else if (remote) { return remote.app.getVersion(); } else { // remote should exist. but sometimes it's undefined and breaks tests for some reason, so adding a temp fallback - return "1.8.16"; + return require("../package.json")?.version || "1.8.34"; } }, recentLogs: (parent: any): Log[] => { diff --git a/tsconfig.json b/tsconfig.json index a2b069cc..fdd8d2de 100644 --- a/tsconfig.json +++ b/tsconfig.json @@ -23,4 +23,4 @@ "include": [ "src/*" ] -} \ No newline at end of file +}