capacitor-ota 1.0.2 → 1.0.3

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.
package/dist/cli/ota.mjs CHANGED
@@ -138,8 +138,8 @@ async function setUrl(url) {
138
138
  async function showConfig() {
139
139
  const config = loadConfig();
140
140
  console.log("\n⚙️ Config:\n");
141
- console.log(` URL: ${config.url}`);
142
- console.log(` Token: ${config.token ? "********" : "(not set)"}\n`);
141
+ console.log(` API URL: ${config.url}`);
142
+ console.log(` Token: ${config.token ? "********" : "(not set)"}\n`);
143
143
  }
144
144
  function printHelp() {
145
145
  console.log(`
@@ -75,7 +75,7 @@ var OtaUpdater = class {
75
75
  throw new Error(`HTTP ${response.status}`);
76
76
  }
77
77
  const data = await response.json();
78
- if (compareVersions(data.version, this.config.appVersion) > 0) {
78
+ if (compareVersions(data.version, this.state.currentVersion) > 0) {
79
79
  this.setState({ newVersion: data.version });
80
80
  return true;
81
81
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "capacitor-ota",
3
- "version": "1.0.2",
3
+ "version": "1.0.3",
4
4
  "type": "module",
5
5
  "main": "dist/src/index.mjs",
6
6
  "types": "dist/src/index.d.mts",