@riocrypto/common-server 1.0.2269 → 1.0.2270

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.
@@ -2,6 +2,7 @@ import mongoose from "mongoose";
2
2
  interface DashboardPushNotificationSubscriptionAttrs {
3
3
  authId?: string;
4
4
  adminAuthId?: string;
5
+ userId?: string;
5
6
  endpoint: string;
6
7
  p256dh: string;
7
8
  auth: string;
@@ -9,6 +10,7 @@ interface DashboardPushNotificationSubscriptionAttrs {
9
10
  interface DashboardPushNotificationSubscriptionDoc extends mongoose.Document {
10
11
  authId?: string;
11
12
  adminAuthId?: string;
13
+ userId?: string;
12
14
  endpoint: string;
13
15
  p256dh: string;
14
16
  auth: string;
@@ -8,6 +8,10 @@ const buildDashboardPushNotificationSubscription = (mongooseInstance) => {
8
8
  return mongooseInstance.model("DashboardPushNotificationSubscription");
9
9
  }
10
10
  const dashboardPushNotificationSubscriptionSchema = new mongooseInstance.Schema({
11
+ userId: {
12
+ type: String,
13
+ index: true, // Good to index if you query by userId often
14
+ },
11
15
  authId: {
12
16
  type: String,
13
17
  index: true, // Good to index if you query by authId often
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@riocrypto/common-server",
3
- "version": "1.0.2269",
3
+ "version": "1.0.2270",
4
4
  "description": "",
5
5
  "main": "./build/index.js",
6
6
  "types": "./build/index.d.ts",