@hot-updater/standalone 1.2.0-rc.40 → 1.2.0-rc.42
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 +11 -2
- package/dist/index.mjs +11 -2
- package/package.json +4 -4
package/dist/index.cjs
CHANGED
|
@@ -76,10 +76,16 @@ const refusal = (status, value, fallback) => {
|
|
|
76
76
|
}
|
|
77
77
|
return new StandaloneDatabaseError("request-failed", message, status);
|
|
78
78
|
};
|
|
79
|
-
const nativeBuildScopeParams = ({ platform, channel, fingerprintHash, appVersion }) => ({
|
|
79
|
+
const nativeBuildScopeParams = ({ platform, channel, fingerprintHash, appVersion, sandbox }) => ({
|
|
80
80
|
platform,
|
|
81
81
|
channel,
|
|
82
|
-
...fingerprintHash === null ? { appVersion } : { fingerprintHash }
|
|
82
|
+
...fingerprintHash === null ? { appVersion } : { fingerprintHash },
|
|
83
|
+
...sandbox === void 0 || sandbox === null ? {} : {
|
|
84
|
+
sandboxAppId: sandbox.appId,
|
|
85
|
+
sandboxUrlScheme: sandbox.urlScheme,
|
|
86
|
+
artifactKind: sandbox.artifactKind,
|
|
87
|
+
distribution: sandbox.distribution
|
|
88
|
+
}
|
|
83
89
|
});
|
|
84
90
|
const keysetParams = ({ order, after, through, limit }) => ({
|
|
85
91
|
limit: String(limit),
|
|
@@ -199,6 +205,8 @@ const createStandaloneCoreApi = (config) => {
|
|
|
199
205
|
});
|
|
200
206
|
if (buildKey !== void 0 && row?.build_key !== buildKey) return null;
|
|
201
207
|
if (options?.storeBuild && row?.is_store_build !== true) return null;
|
|
208
|
+
const sandbox = scope.sandbox;
|
|
209
|
+
if (sandbox && row !== null && (row.is_sandbox !== true || row.artifact_kind !== sandbox.artifactKind || row.sandbox_url_scheme !== sandbox.urlScheme)) return null;
|
|
202
210
|
return row;
|
|
203
211
|
},
|
|
204
212
|
listNativeBuilds: ({ channelId, ...input }) => list("/native-builds", {
|
|
@@ -277,6 +285,7 @@ const createStandaloneCoreApi = (config) => {
|
|
|
277
285
|
requiredRoute: "iOS device registry"
|
|
278
286
|
});
|
|
279
287
|
},
|
|
288
|
+
findIosDeviceAccount: () => call("GET", "/ios-devices/account", { requiredRoute: "iOS device registry" }),
|
|
280
289
|
claimIosDeviceAccount: async (issuerId) => await call("POST", "/ios-devices/account", {
|
|
281
290
|
body: { issuerId },
|
|
282
291
|
requiredRoute: "iOS device registry"
|
package/dist/index.mjs
CHANGED
|
@@ -75,10 +75,16 @@ const refusal = (status, value, fallback) => {
|
|
|
75
75
|
}
|
|
76
76
|
return new StandaloneDatabaseError("request-failed", message, status);
|
|
77
77
|
};
|
|
78
|
-
const nativeBuildScopeParams = ({ platform, channel, fingerprintHash, appVersion }) => ({
|
|
78
|
+
const nativeBuildScopeParams = ({ platform, channel, fingerprintHash, appVersion, sandbox }) => ({
|
|
79
79
|
platform,
|
|
80
80
|
channel,
|
|
81
|
-
...fingerprintHash === null ? { appVersion } : { fingerprintHash }
|
|
81
|
+
...fingerprintHash === null ? { appVersion } : { fingerprintHash },
|
|
82
|
+
...sandbox === void 0 || sandbox === null ? {} : {
|
|
83
|
+
sandboxAppId: sandbox.appId,
|
|
84
|
+
sandboxUrlScheme: sandbox.urlScheme,
|
|
85
|
+
artifactKind: sandbox.artifactKind,
|
|
86
|
+
distribution: sandbox.distribution
|
|
87
|
+
}
|
|
82
88
|
});
|
|
83
89
|
const keysetParams = ({ order, after, through, limit }) => ({
|
|
84
90
|
limit: String(limit),
|
|
@@ -198,6 +204,8 @@ const createStandaloneCoreApi = (config) => {
|
|
|
198
204
|
});
|
|
199
205
|
if (buildKey !== void 0 && row?.build_key !== buildKey) return null;
|
|
200
206
|
if (options?.storeBuild && row?.is_store_build !== true) return null;
|
|
207
|
+
const sandbox = scope.sandbox;
|
|
208
|
+
if (sandbox && row !== null && (row.is_sandbox !== true || row.artifact_kind !== sandbox.artifactKind || row.sandbox_url_scheme !== sandbox.urlScheme)) return null;
|
|
201
209
|
return row;
|
|
202
210
|
},
|
|
203
211
|
listNativeBuilds: ({ channelId, ...input }) => list("/native-builds", {
|
|
@@ -276,6 +284,7 @@ const createStandaloneCoreApi = (config) => {
|
|
|
276
284
|
requiredRoute: "iOS device registry"
|
|
277
285
|
});
|
|
278
286
|
},
|
|
287
|
+
findIosDeviceAccount: () => call("GET", "/ios-devices/account", { requiredRoute: "iOS device registry" }),
|
|
279
288
|
claimIosDeviceAccount: async (issuerId) => await call("POST", "/ios-devices/account", {
|
|
280
289
|
body: { issuerId },
|
|
281
290
|
requiredRoute: "iOS device registry"
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@hot-updater/standalone",
|
|
3
|
-
"version": "1.2.0-rc.
|
|
3
|
+
"version": "1.2.0-rc.42",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"description": "React Native OTA solution for self-hosted",
|
|
6
6
|
"sideEffects": false,
|
|
@@ -42,8 +42,8 @@
|
|
|
42
42
|
"access": "public"
|
|
43
43
|
},
|
|
44
44
|
"dependencies": {
|
|
45
|
-
"@hot-updater/protocol": "1.2.0-rc.
|
|
46
|
-
"@hot-updater/plugin-core": "1.2.0-rc.
|
|
45
|
+
"@hot-updater/protocol": "1.2.0-rc.42",
|
|
46
|
+
"@hot-updater/plugin-core": "1.2.0-rc.42"
|
|
47
47
|
},
|
|
48
48
|
"devDependencies": {
|
|
49
49
|
"mime": "2.6.0",
|
|
@@ -52,7 +52,7 @@
|
|
|
52
52
|
"msw": "^2.7.0",
|
|
53
53
|
"verkit": "0.4.0",
|
|
54
54
|
"vitest": "4.1.4",
|
|
55
|
-
"@hot-updater/test-utils": "1.2.0-rc.
|
|
55
|
+
"@hot-updater/test-utils": "1.2.0-rc.42"
|
|
56
56
|
},
|
|
57
57
|
"scripts": {
|
|
58
58
|
"build": "tsdown",
|