@statsig/js-user-persisted-storage 3.33.2 → 3.33.3

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@statsig/js-user-persisted-storage",
3
- "version": "3.33.2",
3
+ "version": "3.33.3",
4
4
  "license": "ISC",
5
5
  "homepage": "https://github.com/statsig-io/js-client-monorepo",
6
6
  "repository": {
@@ -9,7 +9,7 @@
9
9
  "directory": "packages/js-user-persisted-storage"
10
10
  },
11
11
  "dependencies": {
12
- "@statsig/client-core": "3.33.2"
12
+ "@statsig/client-core": "3.33.3"
13
13
  },
14
14
  "type": "commonjs",
15
15
  "main": "./src/index.js",
@@ -110,18 +110,18 @@ class UserPersistentOverrideAdapter {
110
110
  });
111
111
  }
112
112
  _handleSaveLayer(user, layer, evaluation) {
113
- var _a, _b;
113
+ var _a, _b, _c;
114
114
  const key = this._getStorageKey(user, 'userID');
115
115
  const values = {
116
116
  value: true,
117
117
  rule_id: evaluation.rule_id,
118
118
  json_value: evaluation.value,
119
119
  secondary_exposures: evaluation.secondary_exposures,
120
- group_name: evaluation.group,
121
- time: (_a = layer.details.lcut) !== null && _a !== void 0 ? _a : 0,
120
+ group_name: (_a = evaluation.group_name) !== null && _a !== void 0 ? _a : null,
121
+ time: (_b = layer.details.lcut) !== null && _b !== void 0 ? _b : 0,
122
122
  undelegated_secondary_exposures: evaluation.undelegated_secondary_exposures,
123
123
  config_delegate: evaluation.allocated_experiment_name,
124
- explicit_parameters: (_b = evaluation.explicit_parameters) !== null && _b !== void 0 ? _b : [],
124
+ explicit_parameters: (_c = evaluation.explicit_parameters) !== null && _c !== void 0 ? _c : [],
125
125
  };
126
126
  this.storage.save(key, layer.name, JSON.stringify(values));
127
127
  }
@@ -135,15 +135,15 @@ class UserPersistentOverrideAdapter {
135
135
  this.storage.delete(key, name);
136
136
  }
137
137
  _handleSave(user, experiment, evaluation) {
138
- var _a;
138
+ var _a, _b;
139
139
  const key = this._getStorageKey(user, evaluation.id_type);
140
140
  const values = {
141
141
  value: true,
142
142
  rule_id: evaluation.rule_id,
143
143
  json_value: evaluation.value,
144
144
  secondary_exposures: evaluation.secondary_exposures,
145
- group_name: evaluation.group,
146
- time: (_a = experiment.details.lcut) !== null && _a !== void 0 ? _a : 0,
145
+ group_name: (_a = evaluation.group_name) !== null && _a !== void 0 ? _a : null,
146
+ time: (_b = experiment.details.lcut) !== null && _b !== void 0 ? _b : 0,
147
147
  config_delegate: null,
148
148
  undelegated_secondary_exposures: evaluation.secondary_exposures,
149
149
  };