@applicaster/zapp-react-native-utils 16.0.0-rc.10 → 16.0.0-rc.12

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.
@@ -87,7 +87,7 @@ export function HooksManager({
87
87
  }: HookManagerArgs): HookManager {
88
88
  hooksManagerLogger.addContext({ targetScreenId: targetScreen.id });
89
89
 
90
- function logHookEvent(func, message, data) {
90
+ function logHookEvent(func, message, data = {}) {
91
91
  func({
92
92
  message,
93
93
  data: __DEV__ ? data : null,
@@ -344,7 +344,6 @@ export function HooksManager({
344
344
  `hookCallback: send app to background, cancelled flow blocker hook ${hookPlugin.identifier} on home screen`,
345
345
  {
346
346
  payload,
347
- hook: hookPlugin,
348
347
  }
349
348
  );
350
349
 
@@ -356,17 +355,13 @@ export function HooksManager({
356
355
  `hookCallback: hook successfully finished: ${hookPlugin.identifier}`,
357
356
  {
358
357
  payload,
359
- hook: hookPlugin,
360
358
  }
361
359
  );
362
360
 
363
361
  if (!callback) {
364
362
  logHookEvent(
365
- hooksManagerLogger.warn,
366
- `hookCallback: ${hookPlugin.identifier} is missing \`callback\`, using hookCallback(default one)`,
367
- {
368
- hookPlugin,
369
- }
363
+ hooksManagerLogger.debug,
364
+ `hookCallback: ${hookPlugin.identifier} is missing \`callback\`, using hookCallback(default one)`
370
365
  );
371
366
 
372
367
  callback = hookCallback;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@applicaster/zapp-react-native-utils",
3
- "version": "16.0.0-rc.10",
3
+ "version": "16.0.0-rc.12",
4
4
  "description": "Applicaster Zapp React Native utilities package",
5
5
  "main": "index.js",
6
6
  "types": "index.d.ts",
@@ -27,7 +27,7 @@
27
27
  },
28
28
  "homepage": "https://github.com/applicaster/quickbrick#readme",
29
29
  "dependencies": {
30
- "@applicaster/applicaster-types": "16.0.0-rc.10",
30
+ "@applicaster/applicaster-types": "16.0.0-rc.12",
31
31
  "buffer": "^5.2.1",
32
32
  "camelize": "^1.0.0",
33
33
  "dayjs": "^1.11.10",
@@ -37,7 +37,7 @@ export function isLiveLegacy(content) {
37
37
  ]);
38
38
 
39
39
  const durationFromExt = R.path(["extensions", "duration"], content);
40
- const durationFromMgr = playerManager.getDuration();
40
+ const durationFromMgr = playerManager.getInstanceController()?.getDuration();
41
41
  const duration = Math.floor(durationFromExt || durationFromMgr);
42
42
 
43
43
  const isLive = R.anyPass([isNotaValidNumber, R.lte(R.__, 0)])(duration);
@@ -81,7 +81,9 @@ function isLiveByManager(): boolean {
81
81
  return true;
82
82
  }
83
83
 
84
- const durationFromPlayerManager = playerManager.getDuration();
84
+ const durationFromPlayerManager = playerManager
85
+ .getInstanceController()
86
+ ?.getDuration();
85
87
 
86
88
  return isLiveByDuration(durationFromPlayerManager);
87
89
  }