react-native-update 10.35.0 → 10.35.1

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.
@@ -6,14 +6,14 @@
6
6
  "lockfileVersion": 3,
7
7
  "ATTENTION": "THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY.",
8
8
  "specifiers": {
9
- "@rnoh/react-native-openharmony@0.72.38": "@rnoh/react-native-openharmony@0.72.38"
9
+ "@rnoh/react-native-openharmony@^0.72.96": "@rnoh/react-native-openharmony@0.72.96"
10
10
  },
11
11
  "packages": {
12
- "@rnoh/react-native-openharmony@0.72.38": {
12
+ "@rnoh/react-native-openharmony@0.72.96": {
13
13
  "name": "",
14
- "version": "0.72.38",
15
- "integrity": "sha512-br5SIrbB0OarSLirenleE7eTOX1lNccMJ7nb/G7qWTyJ7kW4DalmTXVKYpoT2qaOLls1uEE7McD1OjbZZM9jug==",
16
- "resolved": "https://ohpm.openharmony.cn/ohpm/@rnoh/react-native-openharmony/-/react-native-openharmony-0.72.38.har",
14
+ "version": "0.72.96",
15
+ "integrity": "sha512-gBbm8LLyqi5UE7qHWdZYeQnjyncfEpCczKZUP/9M2U1Z7exR0Kya8PMKMwr1ta5ujy7w/hZVC2LomEV4QvBeqA==",
16
+ "resolved": "https://ohpm.openharmony.cn/ohpm/@rnoh/react-native-openharmony/-/react-native-openharmony-0.72.96.har",
17
17
  "registryType": "ohpm"
18
18
  }
19
19
  }
@@ -1,13 +1,13 @@
1
1
  {
2
- "license": "MIT",
3
- "types": "",
4
- "devDependencies": {},
5
- "name": "pushy",
6
- "description": "",
7
- "main": "index.ets",
8
- "version": "3.1.0-0.0.7",
9
- "dependencies": {
10
- "@rnoh/react-native-openharmony":"^0.72.38"
2
+ license: 'MIT',
3
+ types: '',
4
+ devDependencies: {},
5
+ name: 'pushy',
6
+ description: '',
7
+ main: 'index.ets',
8
+ version: '10.35.1',
9
+ dependencies: {
10
+ '@rnoh/react-native-openharmony': '^0.72.96',
11
11
  },
12
- "modelVersion": "5.0.0"
12
+ modelVersion: '5.0.0',
13
13
  }
@@ -23,6 +23,11 @@ export class PushyFileJSBundleProvider extends JSBundleProvider {
23
23
  }
24
24
 
25
25
  async getBundle(): Promise<FileJSBundle> {
26
+ if (!this.path) {
27
+ throw new JSBundleProviderError({
28
+ whatHappened: 'No pushy bundle found. using default bundle',
29
+ })
30
+ }
26
31
  try {
27
32
  const status = await fs.access(this.path, fs.OpenMode.READ_ONLY);
28
33
  if (status) {
@@ -30,7 +35,6 @@ export class PushyFileJSBundleProvider extends JSBundleProvider {
30
35
  filePath: this.path
31
36
  }
32
37
  }
33
- throw new Error('Update bundle not found');
34
38
  } catch (error) {
35
39
  throw new JSBundleProviderError({
36
40
  whatHappened: `Couldn't load JSBundle from ${this.path}`,
@@ -189,18 +189,11 @@ export class UpdateContext {
189
189
  }
190
190
  }
191
191
 
192
- public static getBundleUrl(
193
- context: common.UIAbilityContext,
194
- defaultAssetsUrl?: string,
195
- ) {
196
- return new UpdateContext(context).getBundleUrl(defaultAssetsUrl);
197
- }
198
-
199
- public getBundleUrl(defaultAssetsUrl?: string) {
192
+ public getBundleUrl() {
200
193
  UpdateContext.isUsingBundleUrl = true;
201
194
  const currentVersion = this.getCurrentVersion();
202
195
  if (!currentVersion) {
203
- return defaultAssetsUrl;
196
+ return '';
204
197
  }
205
198
  if (!this.isFirstTime()) {
206
199
  if (!this.preferences.getSync('firstTimeOk', true)) {
@@ -222,7 +215,7 @@ export class UpdateContext {
222
215
  version = this.rollBack();
223
216
  }
224
217
  }
225
- return defaultAssetsUrl;
218
+ return '';
226
219
  }
227
220
 
228
221
  getPackageVersion(): string {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "react-native-update",
3
- "version": "10.35.0",
3
+ "version": "10.35.1",
4
4
  "description": "react-native hot update",
5
5
  "main": "src/index",
6
6
  "scripts": {