@vizamodo/viza-cli 1.2.14 → 1.2.17

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -108,7 +108,12 @@ export async function checkForCliUpdateSoft() {
108
108
  if (existsSync(cachePath)) {
109
109
  const raw = readFileSync(cachePath, "utf8");
110
110
  const cached = JSON.parse(raw);
111
- if (cached.checkedAt && (now - cached.checkedAt) < ttl) {
111
+ // Invalidate cache if CLI version has changed since last check
112
+ const curNow = getCliVersion();
113
+ if (cached.current && cached.current !== curNow) {
114
+ // ignore stale cache
115
+ }
116
+ else if (cached.checkedAt && (now - cached.checkedAt) < ttl) {
112
117
  return cached;
113
118
  }
114
119
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@vizamodo/viza-cli",
3
- "version": "1.2.14",
3
+ "version": "1.2.17",
4
4
  "type": "module",
5
5
  "description": "Viza unified command line interface",
6
6
  "bin": {