@ninetailed/experience.js 7.5.0-beta.1 → 7.5.0-beta.2
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/index.cjs +6 -0
- package/index.js +6 -0
- package/package.json +2 -2
package/index.cjs
CHANGED
|
@@ -292,6 +292,12 @@ const ninetailedCorePlugin = ({
|
|
|
292
292
|
instance.storage.removeItem(PROFILE_FALLBACK_CACHE);
|
|
293
293
|
instance.storage.removeItem(EXPERIENCES_FALLBACK_CACHE);
|
|
294
294
|
experience_jsShared.logger.debug('Removed old profile data from localstorage.');
|
|
295
|
+
if (typeof onInitProfileId === 'function') {
|
|
296
|
+
const profileId = onInitProfileId(undefined);
|
|
297
|
+
if (typeof profileId === 'string') {
|
|
298
|
+
instance.storage.setItem(ANONYMOUS_ID, profileId);
|
|
299
|
+
}
|
|
300
|
+
}
|
|
295
301
|
yield ninetailed.track('nt_reset');
|
|
296
302
|
experience_jsShared.logger.info('Profile reset successful.');
|
|
297
303
|
yield delay(10);
|
package/index.js
CHANGED
|
@@ -285,6 +285,12 @@ const ninetailedCorePlugin = ({
|
|
|
285
285
|
instance.storage.removeItem(PROFILE_FALLBACK_CACHE);
|
|
286
286
|
instance.storage.removeItem(EXPERIENCES_FALLBACK_CACHE);
|
|
287
287
|
logger.debug('Removed old profile data from localstorage.');
|
|
288
|
+
if (typeof onInitProfileId === 'function') {
|
|
289
|
+
const profileId = onInitProfileId(undefined);
|
|
290
|
+
if (typeof profileId === 'string') {
|
|
291
|
+
instance.storage.setItem(ANONYMOUS_ID, profileId);
|
|
292
|
+
}
|
|
293
|
+
}
|
|
288
294
|
yield ninetailed.track('nt_reset');
|
|
289
295
|
logger.info('Profile reset successful.');
|
|
290
296
|
yield delay(10);
|
package/package.json
CHANGED
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@ninetailed/experience.js",
|
|
3
|
-
"version": "7.5.0-beta.
|
|
3
|
+
"version": "7.5.0-beta.2",
|
|
4
4
|
"license": "BSL-1.1",
|
|
5
5
|
"module": "./index.js",
|
|
6
6
|
"main": "./index.cjs",
|
|
7
7
|
"type": "module",
|
|
8
8
|
"types": "./src/index.d.ts",
|
|
9
9
|
"dependencies": {
|
|
10
|
-
"@ninetailed/experience.js-shared": "7.5.0-beta.
|
|
10
|
+
"@ninetailed/experience.js-shared": "7.5.0-beta.2",
|
|
11
11
|
"analytics": "0.8.1",
|
|
12
12
|
"zod": "3.21.4"
|
|
13
13
|
},
|