web-manager 4.1.28 → 4.1.30

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/CHANGELOG.md CHANGED
@@ -14,6 +14,19 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/).
14
14
  - `Fixed` for any bug fixes.
15
15
  - `Security` in case of vulnerabilities.
16
16
 
17
+ ---
18
+ ## [4.1.30] - 2026-03-20
19
+ ### Changed
20
+ - Bumped `@sentry/browser` from `^10.43.0` to `^10.45.0`.
21
+ - Bumped `chatsy` from `^2.0.9` to `^2.0.11`.
22
+ - Bumped `firebase` from `^12.10.0` to `^12.11.0`.
23
+
24
+ ---
25
+ ## [4.1.29] - 2026-03-19
26
+ ### Changed
27
+ - Restructured notification subscription documents to use nested `metadata.created` and `metadata.updated` timestamps instead of top-level fields.
28
+ - Update operations now use dot-notation (`metadata.updated`) to preserve `metadata.created` when updating existing subscriptions.
29
+
17
30
  ---
18
31
  ## [4.1.28] - 2026-03-15
19
32
  ### Changed
@@ -282,34 +282,28 @@ class Notifications {
282
282
  const existingOwner = existingData?.owner || null;
283
283
  const needsUpdate = existingOwner !== currentUid;
284
284
 
285
- // Common data for both create and update
286
- const baseData = {
287
- context: {
288
- client: clientData
289
- },
290
- updated: {
291
- timestamp,
292
- timestampUNIX
293
- },
294
- owner: currentUid
295
- };
296
-
297
285
  // Create or update the document as needed
298
286
  if (!existingData) {
299
287
  // New subscription - create the document
300
288
  await notificationDoc.set({
301
- ...baseData,
302
289
  token,
290
+ owner: currentUid,
303
291
  tags: ['general'],
304
292
  attribution: storage.get('attribution', {}),
305
- created: {
306
- timestamp,
307
- timestampUNIX
293
+ context: { client: clientData },
294
+ metadata: {
295
+ created: { timestamp, timestampUNIX },
296
+ updated: { timestamp, timestampUNIX },
308
297
  },
309
298
  });
310
299
  } else if (needsUpdate) {
311
300
  // Existing subscription needs update (userId changed)
312
- await notificationDoc.update(baseData);
301
+ // Use dot-notation to avoid overwriting metadata.created
302
+ await notificationDoc.update({
303
+ owner: currentUid,
304
+ context: { client: clientData },
305
+ 'metadata.updated': { timestamp, timestampUNIX },
306
+ });
313
307
  }
314
308
  // If no update needed, do nothing
315
309
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "web-manager",
3
- "version": "4.1.28",
3
+ "version": "4.1.30",
4
4
  "description": "Easily access important variables such as the query string, current domain, and current page in a single object.",
5
5
  "main": "dist/index.js",
6
6
  "module": "src/index.js",
@@ -43,9 +43,9 @@
43
43
  "@sentry/browser": "Resolved by using OVERRIDES in web-manager (lighthouse is the issue"
44
44
  },
45
45
  "dependencies": {
46
- "@sentry/browser": "^10.43.0",
47
- "chatsy": "^2.0.9",
48
- "firebase": "^12.10.0",
46
+ "@sentry/browser": "^10.45.0",
47
+ "chatsy": "^2.0.11",
48
+ "firebase": "^12.11.0",
49
49
  "itwcw-package-analytics": "^1.0.8",
50
50
  "lodash": "^4.17.23"
51
51
  },