@capgo/capacitor-updater 4.61.4 → 4.61.6
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/android/src/main/java/ee/forgr/capacitor_updater/CapacitorUpdater.java +1 -2
- package/android/src/main/java/ee/forgr/capacitor_updater/CapacitorUpdaterPlugin.java +3 -2
- package/ios/Plugin/CapacitorUpdater.swift +2 -2
- package/ios/Plugin/CapacitorUpdaterPlugin.swift +2 -1
- package/package.json +1 -1
|
@@ -1015,8 +1015,7 @@ public class CapacitorUpdater {
|
|
|
1015
1015
|
result = new BundleInfo(trueId, null, BundleStatus.PENDING, "", "");
|
|
1016
1016
|
}
|
|
1017
1017
|
}
|
|
1018
|
-
|
|
1019
|
-
Log.d(TAG, "Returning info [" + trueId + "] " + result);
|
|
1018
|
+
// Log.d(TAG, "Returning info [" + trueId + "] " + result);
|
|
1020
1019
|
return result;
|
|
1021
1020
|
}
|
|
1022
1021
|
|
|
@@ -55,7 +55,7 @@ public class CapacitorUpdaterPlugin
|
|
|
55
55
|
private static final String channelUrlDefault =
|
|
56
56
|
"https://api.capgo.app/channel_self";
|
|
57
57
|
|
|
58
|
-
private final String PLUGIN_VERSION = "4.61.
|
|
58
|
+
private final String PLUGIN_VERSION = "4.61.6";
|
|
59
59
|
private static final String DELAY_CONDITION_PREFERENCES = "";
|
|
60
60
|
|
|
61
61
|
private SharedPreferences.Editor editor;
|
|
@@ -106,7 +106,8 @@ public class CapacitorUpdaterPlugin
|
|
|
106
106
|
.getPackageManager()
|
|
107
107
|
.getPackageInfo(this.getContext().getPackageName(), 0);
|
|
108
108
|
this.implementation.activity = this.getActivity();
|
|
109
|
-
this.implementation.versionBuild =
|
|
109
|
+
this.implementation.versionBuild =
|
|
110
|
+
this.getConfig().getString("version", pInfo.versionName);
|
|
110
111
|
this.implementation.PLUGIN_VERSION = this.PLUGIN_VERSION;
|
|
111
112
|
this.implementation.versionCode = Integer.toString(pInfo.versionCode);
|
|
112
113
|
this.implementation.requestQueue =
|
|
@@ -219,7 +219,6 @@ extension CustomError: LocalizedError {
|
|
|
219
219
|
|
|
220
220
|
@objc public class CapacitorUpdater: NSObject {
|
|
221
221
|
|
|
222
|
-
private let versionName: String = Bundle.main.versionName ?? ""
|
|
223
222
|
private let versionCode: String = Bundle.main.versionCode ?? ""
|
|
224
223
|
private let versionOs = UIDevice.current.systemVersion
|
|
225
224
|
private let documentsDir: URL = FileManager.default.urls(for: .documentDirectory, in: .userDomainMask).first!
|
|
@@ -233,6 +232,7 @@ extension CustomError: LocalizedError {
|
|
|
233
232
|
|
|
234
233
|
public let TAG: String = "✨ Capacitor-updater:"
|
|
235
234
|
public let CAP_SERVER_PATH: String = "serverBasePath"
|
|
235
|
+
public var versionName: String = ""
|
|
236
236
|
public var customId: String = ""
|
|
237
237
|
public var PLUGIN_VERSION: String = ""
|
|
238
238
|
public let timeout: Double = 20
|
|
@@ -755,7 +755,7 @@ extension CustomError: LocalizedError {
|
|
|
755
755
|
result = BundleInfo(id: trueId, version: "", status: BundleStatus.PENDING, checksum: "")
|
|
756
756
|
}
|
|
757
757
|
}
|
|
758
|
-
print("\(self.TAG) Returning info bundle [\(result.toString())]")
|
|
758
|
+
// print("\(self.TAG) Returning info bundle [\(result.toString())]")
|
|
759
759
|
return result
|
|
760
760
|
}
|
|
761
761
|
|
|
@@ -15,7 +15,7 @@ import Version
|
|
|
15
15
|
@objc(CapacitorUpdaterPlugin)
|
|
16
16
|
public class CapacitorUpdaterPlugin: CAPPlugin {
|
|
17
17
|
private var implementation = CapacitorUpdater()
|
|
18
|
-
private let PLUGIN_VERSION: String = "4.61.
|
|
18
|
+
private let PLUGIN_VERSION: String = "4.61.6"
|
|
19
19
|
static let updateUrlDefault = "https://api.capgo.app/updates"
|
|
20
20
|
static let statsUrlDefault = "https://api.capgo.app/stats"
|
|
21
21
|
static let channelUrlDefault = "https://api.capgo.app/channel_self"
|
|
@@ -41,6 +41,7 @@ public class CapacitorUpdaterPlugin: CAPPlugin {
|
|
|
41
41
|
} catch {
|
|
42
42
|
print("\(self.implementation.TAG) Cannot get version native \(currentVersionNative)")
|
|
43
43
|
}
|
|
44
|
+
implementation.versionName = getConfig().getString("version", Bundle.main.versionName)!
|
|
44
45
|
autoDeleteFailed = getConfig().getBoolean("autoDeleteFailed", true)
|
|
45
46
|
autoDeletePrevious = getConfig().getBoolean("autoDeletePrevious", true)
|
|
46
47
|
updateUrl = getConfig().getString("updateUrl", CapacitorUpdaterPlugin.updateUrlDefault)!
|