@applicaster/zapp-react-native-bridge 12.0.4-rc.2 → 12.0.4

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.
@@ -85,37 +85,40 @@ export const remapAssetPath = (
85
85
  ): Record<string, any> => {
86
86
  const startTime = performance.now();
87
87
 
88
- const result = assets.reduce((obj, { path, url }) => {
89
- const localFile = localFiles[url];
90
-
91
- if (!localFile) {
92
- bridgeLogger.warning({
93
- message: `remapAssetPath: Could not replace asset with local file for url: ${url}`,
94
- data: { path, obj },
95
- });
88
+ const result = assets.reduce(
89
+ (obj, { path, url }) => {
90
+ const localFile = localFiles[url];
91
+
92
+ if (!localFile) {
93
+ bridgeLogger.warning({
94
+ message: `remapAssetPath: Could not replace asset with local file for url: ${url}`,
95
+ data: { path, obj },
96
+ });
97
+
98
+ return obj;
99
+ }
100
+
101
+ let target = obj;
102
+
103
+ // Traverse the path to the appropriate nested object
104
+ for (let i = 0; i < path.length - 1; i++) {
105
+ target = target[path[i]] = target[path[i]];
106
+ }
107
+
108
+ if (!target) {
109
+ bridgeLogger.error({
110
+ message: `remapAssetPath: Could not find path ${path.join(".")}`,
111
+ data: obj,
112
+ });
113
+ } else {
114
+ // Set the final value
115
+ target[path[path.length - 1]] = localFile;
116
+ }
96
117
 
97
118
  return obj;
98
- }
99
-
100
- let target = obj;
101
-
102
- // Traverse the path to the appropriate nested object
103
- for (let i = 0; i < path.length - 1; i++) {
104
- target = target[path[i]] = target[path[i]];
105
- }
106
-
107
- if (!target) {
108
- bridgeLogger.error({
109
- message: `remapAssetPath: Could not find path ${path.join(".")}`,
110
- data: obj,
111
- });
112
- } else {
113
- // Set the final value
114
- target[path[path.length - 1]] = localFile;
115
- }
116
-
117
- return obj;
118
- }, JSON.parse(JSON.stringify(source)));
119
+ },
120
+ JSON.parse(JSON.stringify(source))
121
+ );
119
122
 
120
123
  bridgeLogger.log({
121
124
  message: `remapAssetPath: remapping took ${
@@ -105,9 +105,8 @@ async function isPluginEnabled(identifier) {
105
105
  return isPluginEnabledNative(identifier);
106
106
  }
107
107
 
108
- const enabledInConfigurationJSON = await isPluginSupportToggleLogic(
109
- identifier
110
- );
108
+ const enabledInConfigurationJSON =
109
+ await isPluginSupportToggleLogic(identifier);
111
110
 
112
111
  if (enabledInConfigurationJSON !== undefined) {
113
112
  const enabledOverriden = await localStorage.getItem(
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@applicaster/zapp-react-native-bridge",
3
- "version": "12.0.4-rc.2",
3
+ "version": "12.0.4",
4
4
  "description": "Applicaster Zapp React Native modules",
5
5
  "main": "index.js",
6
6
  "types": "index.d.ts",
@@ -33,7 +33,7 @@
33
33
  "homepage": "https://github.com/applicaster/quickbrick#readme",
34
34
  "dependencies": {
35
35
  "@applicaster/zapp-pipes-dev-kit": "1.4.7",
36
- "@applicaster/zapp-react-native-utils": "12.0.4-rc.2",
36
+ "@applicaster/zapp-react-native-utils": "12.0.4",
37
37
  "md5": "^2.3.0",
38
38
  "uuid": "^3.3.2"
39
39
  },