@hot-updater/standalone 0.25.11 → 0.25.14
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/index.cjs +7 -4
- package/dist/index.js +7 -4
- package/package.json +3 -3
package/dist/index.cjs
CHANGED
|
@@ -101,11 +101,14 @@ const standaloneRepository = (0, __hot_updater_plugin_core.createDatabasePlugin)
|
|
|
101
101
|
};
|
|
102
102
|
},
|
|
103
103
|
async getChannels() {
|
|
104
|
-
const
|
|
105
|
-
|
|
106
|
-
|
|
104
|
+
const { path: path$2, headers: routeHeaders } = routes.list();
|
|
105
|
+
const response = await fetch(buildUrl(path$2), {
|
|
106
|
+
method: "GET",
|
|
107
|
+
headers: getHeaders(routeHeaders)
|
|
107
108
|
});
|
|
108
|
-
|
|
109
|
+
if (!response.ok) throw new Error(`API Error: ${response.statusText}`);
|
|
110
|
+
const channels = (await response.json()).map((b) => b.channel);
|
|
111
|
+
return [...new Set(channels)];
|
|
109
112
|
},
|
|
110
113
|
async commitBundle({ changedSets }) {
|
|
111
114
|
if (changedSets.length === 0) return;
|
package/dist/index.js
CHANGED
|
@@ -98,11 +98,14 @@ const standaloneRepository = createDatabasePlugin({
|
|
|
98
98
|
};
|
|
99
99
|
},
|
|
100
100
|
async getChannels() {
|
|
101
|
-
const
|
|
102
|
-
|
|
103
|
-
|
|
101
|
+
const { path: path$1, headers: routeHeaders } = routes.list();
|
|
102
|
+
const response = await fetch(buildUrl(path$1), {
|
|
103
|
+
method: "GET",
|
|
104
|
+
headers: getHeaders(routeHeaders)
|
|
104
105
|
});
|
|
105
|
-
|
|
106
|
+
if (!response.ok) throw new Error(`API Error: ${response.statusText}`);
|
|
107
|
+
const channels = (await response.json()).map((b) => b.channel);
|
|
108
|
+
return [...new Set(channels)];
|
|
106
109
|
},
|
|
107
110
|
async commitBundle({ changedSets }) {
|
|
108
111
|
if (changedSets.length === 0) return;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@hot-updater/standalone",
|
|
3
|
-
"version": "0.25.
|
|
3
|
+
"version": "0.25.14",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"description": "React Native OTA solution for self-hosted",
|
|
6
6
|
"sideEffects": false,
|
|
@@ -39,8 +39,8 @@
|
|
|
39
39
|
"access": "public"
|
|
40
40
|
},
|
|
41
41
|
"dependencies": {
|
|
42
|
-
"@hot-updater/core": "0.25.
|
|
43
|
-
"@hot-updater/plugin-core": "0.25.
|
|
42
|
+
"@hot-updater/core": "0.25.14",
|
|
43
|
+
"@hot-updater/plugin-core": "0.25.14"
|
|
44
44
|
},
|
|
45
45
|
"devDependencies": {
|
|
46
46
|
"mime": "2.6.0",
|