From 9db030eb8c20d65f749fc2313bc1237b7003053d Mon Sep 17 00:00:00 2001 From: Lukas Wolfsteiner Date: Mon, 6 Jul 2026 11:21:14 +0200 Subject: [PATCH] fix: check target version key when updating versions.json Check whether the target version key already exists instead of whether the minAppVersion value exists. The old check incorrectly skipped writing a new entry when a prior release mapped to the same minimum app version. Ensures every release gets its own entry in the version map. Co-authored-by: Cursor --- version-bump.mjs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/version-bump.mjs b/version-bump.mjs index fd3925d..cb5226f 100644 --- a/version-bump.mjs +++ b/version-bump.mjs @@ -11,7 +11,7 @@ writeFileSync("manifest.json", JSON.stringify(manifest, null, "\t")); // update versions.json with target version and minAppVersion from manifest.json // but only if the target version is not already in versions.json const versions = JSON.parse(readFileSync('versions.json', 'utf8')); -if (!versions[targetVersion]) { - versions[targetVersion] = minAppVersion; - writeFileSync('versions.json', JSON.stringify(versions, null, '\t')); +if (!(targetVersion in versions)) { + versions[targetVersion] = minAppVersion; + writeFileSync('versions.json', JSON.stringify(versions, null, '\t')); }