@braze/web-sdk 6.9.0 → 6.10.1

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.
@@ -48,12 +48,12 @@ export default class Vt {
48
48
  Z(t, e = !1, i = !1) {
49
49
  const r = this.eu.ve(!i),
50
50
  n = r.ta(),
51
- o = this.j.St(s.It.Ba);
51
+ o = this.j.St(s.It.Ha);
52
52
  oi(o, n) || (t.device = n),
53
53
  (t.api_key = this.tu),
54
54
  (t.time = X(new Date().valueOf(), !0));
55
- const a = this.j.St(s.It.Ka) || [],
56
- h = this.j.St(s.It.Pa) || "";
55
+ const a = this.j.St(s.It.Pa) || [],
56
+ h = this.j.St(s.It.Ua) || "";
57
57
  this.$a.length > 0 &&
58
58
  (!oi(a, this.$a) || h !== this.C.$t()) &&
59
59
  (t.sdk_metadata = this.$a),
@@ -91,7 +91,7 @@ export default class Vt {
91
91
  (e +=
92
92
  ' Please use the "enableSdkAuthentication" initialization option to enable authentication.'),
93
93
  b.error(`SDK Authentication failed ${e}`),
94
- this.Ua(t.events || [], t.attributes || []),
94
+ this.Wa(t.events || [], t.attributes || []),
95
95
  this.Gh.Ch(r),
96
96
  !1
97
97
  );
@@ -100,28 +100,28 @@ export default class Vt {
100
100
  let i,
101
101
  s = r;
102
102
  switch (s) {
103
- case Ne.Wa:
103
+ case Ne.Ya:
104
104
  return (
105
105
  (i = "Received successful response with empty body."),
106
- v.Dt(p.Ya, { e: i }),
106
+ v.Dt(p.Qa, { e: i }),
107
107
  b.info(i),
108
108
  !1
109
109
  );
110
- case Ne.Qa:
110
+ case Ne.Va:
111
111
  return (
112
112
  (i = "Received successful response with invalid JSON"),
113
- v.Dt(p.Ya, { e: i + ": " + e.response }),
113
+ v.Dt(p.Qa, { e: i + ": " + e.response }),
114
114
  b.info(i),
115
115
  !1
116
116
  );
117
- case Ne.Va:
117
+ case Ne.Za:
118
118
  s = `The API key "${t.api_key}" is invalid for the baseUrl ${this.Yh}`;
119
119
  break;
120
- case Ne.Za:
120
+ case Ne.dl:
121
121
  s =
122
122
  "Sorry, we are not currently accepting your requests. If you think this is in error, please contact us.";
123
123
  break;
124
- case Ne.dl:
124
+ case Ne.fl:
125
125
  s =
126
126
  "No device identifier. Please contact Braze Technical Support for assistance.";
127
127
  }
@@ -129,10 +129,10 @@ export default class Vt {
129
129
  }
130
130
  return !1;
131
131
  }
132
- fl(t, e, i) {
132
+ ml(t, e, i) {
133
133
  return !!((t && 0 !== t.length) || (e && 0 !== e.length) || i);
134
134
  }
135
- ml(t, e, i, s = !1) {
135
+ vl(t, e, i, s = !1) {
136
136
  const r = [],
137
137
  n = (t) => t || "",
138
138
  o = n(this.Ss.getUserId());
@@ -164,16 +164,16 @@ export default class Vt {
164
164
  e && (this.Gh.Fh() && n(e.user_id) !== o ? u.push(e) : t.push(e));
165
165
  t.length > 0 && (a.attributes = t);
166
166
  }
167
- if ((this.Ua(l, u), (a = this.Z(a, !1, s)), d)) {
167
+ if ((this.Wa(l, u), (a = this.Z(a, !1, s)), d)) {
168
168
  d = this.Z(d, !1, s);
169
169
  const t = { requestData: d, headers: this.tt(d, h.it.pn) };
170
170
  r.push(t);
171
171
  }
172
- if (a && !this.fl(a.events, a.attributes, t)) return d ? r : null;
172
+ if (a && !this.ml(a.events, a.attributes, t)) return d ? r : null;
173
173
  const f = { requestData: a, headers: this.tt(a, h.it.pn) };
174
174
  return r.push(f), r;
175
175
  }
176
- Ua(t, e) {
176
+ Wa(t, e) {
177
177
  if (t) {
178
178
  const e = [];
179
179
  for (const i of t) {
@@ -182,14 +182,14 @@ export default class Vt {
182
182
  }
183
183
  this.j.ol(e);
184
184
  }
185
- if (e) for (const t of e) this.j.vl(t);
185
+ if (e) for (const t of e) this.j.Rl(t);
186
186
  }
187
187
  dt(t, e) {
188
188
  let i = "HTTP error ";
189
189
  null != t && (i += t + " "), (i += e), b.error(i);
190
190
  }
191
- Rl(t) {
192
- return v.Dt(p.gl, { n: t });
191
+ gl(t) {
192
+ return v.Dt(p.bl, { n: t });
193
193
  }
194
194
  Zo(t, e) {
195
195
  const i = {};
@@ -201,10 +201,10 @@ export default class Vt {
201
201
  }
202
202
  return (i.config = { config_time: this.h.Qt() }), { respond_with: i };
203
203
  }
204
- bl(t) {
204
+ ql(t) {
205
205
  const e = new Date().valueOf();
206
206
  let i = Ke.toString();
207
- const s = h.ql(this.j, t);
207
+ const s = h.Al(this.j, t);
208
208
  if (-1 !== s) {
209
209
  i = (e - s).toString();
210
210
  }
@@ -212,9 +212,9 @@ export default class Vt {
212
212
  }
213
213
  tt(t, e, i = "sdk") {
214
214
  const s = [["X-Braze-Api-Key", this.tu]],
215
- r = this.bl(e);
215
+ r = this.ql(e);
216
216
  s.push(["X-Braze-Last-Req-Ms-Ago", r]);
217
- const n = h.Al(this.j, e).toString();
217
+ const n = h.Dl(this.j, e).toString();
218
218
  s.push(["X-Braze-Req-Attempt", n]);
219
219
  let o = !1;
220
220
  if (
@@ -224,8 +224,8 @@ export default class Vt {
224
224
  e === h.it.Mi)
225
225
  ) {
226
226
  s.push(["X-Braze-ContentCardsRequest", "true"]);
227
- let t = h.Al(this.j, h.it.Mi);
228
- (t && "client" !== i) || ((t = 1), h.Dl(this.j, h.it.Mi, t));
227
+ let t = h.Dl(this.j, h.it.Mi);
228
+ (t && "client" !== i) || ((t = 1), h.Tl(this.j, h.it.Mi, t));
229
229
  const e = Math.max(0, t - 1);
230
230
  s.push(["BRAZE-SYNC-RETRY-COUNT", e.toString()]), (o = !0);
231
231
  }
@@ -241,7 +241,7 @@ export default class Vt {
241
241
  }
242
242
  return s;
243
243
  }
244
- Tl(t, e, i, s) {
244
+ kl(t, e, i, s) {
245
245
  if (this.La[s]) return;
246
246
  const r = window.setTimeout(() => {
247
247
  b.info(`Retrying rate limited ${this.Xa(s)}SDK request.`),
@@ -257,32 +257,32 @@ export default class Vt {
257
257
  this.La = {};
258
258
  }
259
259
  et(t, e, i, r) {
260
- if (!this.kl(i))
260
+ if (!this.yl(i))
261
261
  return (
262
262
  b.info(`${this.Xa(i)}SDK request being rate limited.`),
263
263
  void ("function" == typeof r && r())
264
264
  );
265
- const n = this.yl();
266
- if (!n.wl)
265
+ const n = this.wl();
266
+ if (!n.Nl)
267
267
  return (
268
- this.Tl(n.Nl, t, e, i),
268
+ this.kl(n.Bl, t, e, i),
269
269
  void b.info(
270
270
  `${this.Xa(
271
271
  i,
272
272
  )}SDK request being rate limited. Request will be retried in ${Math.trunc(
273
- n.Nl / 1e3,
273
+ n.Bl / 1e3,
274
274
  )} seconds.`,
275
275
  )
276
276
  );
277
- this.j.Pt(s.It.Bl, new Date().valueOf());
277
+ this.j.Pt(s.It.Sl, new Date().valueOf());
278
278
  const o = t.device;
279
279
  o && o.os_version instanceof Promise
280
280
  ? o.os_version.then((i) => {
281
- (t.device.os_version = i), e(n.Sl);
281
+ (t.device.os_version = i), e(n.Cl);
282
282
  })
283
- : e(n.Sl);
283
+ : e(n.Cl);
284
284
  }
285
- Cl(t) {
285
+ zl(t) {
286
286
  const e = t ? Oe(t) : null;
287
287
  if (!e || !e["retry-after"]) return null;
288
288
  const i = e["retry-after"];
@@ -293,21 +293,21 @@ export default class Vt {
293
293
  {
294
294
  const t =
295
295
  "Received unexpected value for retry-after header in /sync response";
296
- v.Dt(p.Ya, { e: t + ": " + i });
296
+ v.Dt(p.Qa, { e: t + ": " + i });
297
297
  }
298
298
  return null;
299
299
  }
300
300
  yt(t, e, i, s, r, n) {
301
- if (h.Al(this.j, i) >= Pe) return;
301
+ if (h.Dl(this.j, i) >= Pe) return;
302
302
  let o;
303
303
  n = n || 0;
304
- const a = this.Cl(t);
304
+ const a = this.zl(t);
305
305
  r();
306
306
  const u = (t) => {
307
307
  const r = window.setTimeout(() => {
308
308
  e();
309
309
  }, t);
310
- s(r), h.zl(this.j, i);
310
+ s(r), h.jl(this.j, i);
311
311
  };
312
312
  if (a && !isNaN(a.value)) {
313
313
  switch (a.type) {
@@ -320,44 +320,44 @@ export default class Vt {
320
320
  u(o);
321
321
  } else n ? u(n) : h.Ji(this.j, i);
322
322
  }
323
- jl(t) {
323
+ Ml(t) {
324
324
  var e;
325
- null === (e = this.j) || void 0 === e || e.Pt(s.It.Ml, t);
325
+ null === (e = this.j) || void 0 === e || e.Pt(s.It.Xl, t);
326
326
  }
327
- Xl(t, e) {
328
- let i = this.$l();
329
- null == i && (i = {}), (i[t] = e), this.j.Pt(s.It.Ll, i);
327
+ $l(t, e) {
328
+ let i = this.Ll();
329
+ null == i && (i = {}), (i[t] = e), this.j.Pt(s.It.El, i);
330
330
  }
331
- El() {
331
+ Fl() {
332
332
  var t;
333
- return null === (t = this.j) || void 0 === t ? void 0 : t.St(s.It.Ml);
333
+ return null === (t = this.j) || void 0 === t ? void 0 : t.St(s.It.Xl);
334
334
  }
335
- $l() {
335
+ Ll() {
336
336
  var t;
337
- return null === (t = this.j) || void 0 === t ? void 0 : t.St(s.It.Ll);
337
+ return null === (t = this.j) || void 0 === t ? void 0 : t.St(s.It.El);
338
338
  }
339
- Fl(t, e, i, s, r = "") {
339
+ Il(t, e, i, s, r = "") {
340
340
  let n;
341
341
  if (r) {
342
- const t = this.$l();
342
+ const t = this.Ll();
343
343
  n = null == t || isNaN(t[r]) ? e : t[r];
344
- } else (n = this.El()), (null == n || isNaN(n)) && (n = e);
344
+ } else (n = this.Fl()), (null == n || isNaN(n)) && (n = e);
345
345
  const o = (t - s) / 1e3;
346
346
  return (n = Math.min(n + o / i, e)), n;
347
347
  }
348
- Il(t, e) {
348
+ Kl(t, e) {
349
349
  return Math.max(0, (1 - t) * e * 1e3);
350
350
  }
351
- Kl(t, e = "") {
351
+ Pl(t, e = "") {
352
352
  var i, r, n, o, a;
353
- const u = { wl: !0, Sl: -1, Nl: 0 };
353
+ const u = { Nl: !0, Cl: -1, Bl: 0 };
354
354
  if ((null == t && (t = !0), !t && !e)) return u;
355
355
  let l,
356
356
  c,
357
357
  d = null;
358
- if (t) d = null === (i = this.j) || void 0 === i ? void 0 : i.St(s.It.Bl);
358
+ if (t) d = null === (i = this.j) || void 0 === i ? void 0 : i.St(s.It.Sl);
359
359
  else {
360
- const t = h.Pl(this.j);
360
+ const t = h.Ul(this.j);
361
361
  if (null == t || null == t[e]) return u;
362
362
  d = t[e];
363
363
  }
@@ -365,30 +365,30 @@ export default class Vt {
365
365
  if (
366
366
  (t
367
367
  ? ((l =
368
- (null === (r = this.h) || void 0 === r ? void 0 : r.Ul()) || -1),
369
- (c = (null === (n = this.h) || void 0 === n ? void 0 : n.xl()) || -1))
368
+ (null === (r = this.h) || void 0 === r ? void 0 : r.xl()) || -1),
369
+ (c = (null === (n = this.h) || void 0 === n ? void 0 : n.Hl()) || -1))
370
370
  : ((l =
371
- (null === (o = this.h) || void 0 === o ? void 0 : o.Hl(e)) || -1),
371
+ (null === (o = this.h) || void 0 === o ? void 0 : o.Ol(e)) || -1),
372
372
  (c =
373
- (null === (a = this.h) || void 0 === a ? void 0 : a.Ol(e)) || -1)),
373
+ (null === (a = this.h) || void 0 === a ? void 0 : a.Gl(e)) || -1)),
374
374
  -1 === l || -1 === c)
375
375
  )
376
376
  return u;
377
377
  const f = new Date().valueOf();
378
- let m = this.Fl(f, l, c, d, e);
378
+ let m = this.Il(f, l, c, d, e);
379
379
  return m < 1
380
- ? ((u.wl = !1), (u.Nl = this.Il(m, c)), u)
380
+ ? ((u.Nl = !1), (u.Bl = this.Kl(m, c)), u)
381
381
  : ((m = Math.trunc(m) - 1),
382
- (u.Sl = m),
383
- t ? this.jl(m) : this.Xl(e, m),
382
+ (u.Cl = m),
383
+ t ? this.Ml(m) : this.$l(e, m),
384
384
  u);
385
385
  }
386
- yl() {
387
- return this.Kl(!0);
386
+ wl() {
387
+ return this.Pl(!0);
388
388
  }
389
- kl(t) {
390
- const e = this.Kl(!1, t);
391
- return !(e && !e.wl);
389
+ yl(t) {
390
+ const e = this.Pl(!1, t);
391
+ return !(e && !e.Nl);
392
392
  }
393
393
  ct() {
394
394
  this.Gh.ct();
@@ -13,31 +13,31 @@ export default class Yt {
13
13
  constructor(t) {
14
14
  (this.j = t),
15
15
  (this.j = t),
16
- (this.Gl = new f()),
17
16
  (this._l = new f()),
18
17
  (this.Vl = new f()),
19
18
  (this.Jl = new f()),
20
19
  (this.Ql = new f()),
21
20
  (this.Wl = new f()),
22
- (this.Yl = null),
23
- (this.Zl = null);
24
- }
25
- ed() {
26
- if (null == this.Zl) {
27
- const t = this.j.St(s.It.sd);
28
- this.Zl = null != t ? di._u(t) : new di();
21
+ (this.Yl = new f()),
22
+ (this.Zl = null),
23
+ (this.ed = null);
24
+ }
25
+ sd() {
26
+ if (null == this.ed) {
27
+ const t = this.j.St(s.It.nd);
28
+ this.ed = null != t ? di._u(t) : new di();
29
29
  }
30
- return this.Zl;
30
+ return this.ed;
31
31
  }
32
32
  Qt() {
33
- return this.ed().nd;
33
+ return this.sd().ld;
34
34
  }
35
- ld(t) {
35
+ ud(t) {
36
36
  var i, e, n, l, r, o;
37
37
  if (null != t && null != t.config) {
38
38
  const u = t.config;
39
- if (u.time > this.ed().nd) {
40
- const t = (t) => (null == t ? this.ed().ud : t),
39
+ if (u.time > this.sd().ld) {
40
+ const t = (t) => (null == t ? this.sd().ad : t),
41
41
  a = new di(
42
42
  u.time,
43
43
  u.events_blacklist,
@@ -55,9 +55,9 @@ export default class Yt {
55
55
  u.conversational_chat,
56
56
  );
57
57
  let h = !1;
58
- null != a.ad && this.ju() !== a.ad && (h = !0);
58
+ null != a.hd && this.ju() !== a.hd && (h = !0);
59
59
  let d = !1;
60
- null != a.hd.enabled && this.Pi() !== a.hd.enabled && (d = !0);
60
+ null != a.dd.enabled && this.Pi() !== a.dd.enabled && (d = !0);
61
61
  let c = !1;
62
62
  null != a.Xr.enabled && this.lo() !== a.Xr.enabled && (c = !0);
63
63
  let v = !1;
@@ -72,105 +72,105 @@ export default class Yt {
72
72
  (null === (l = a.dust) || void 0 === l ? void 0 : l.enabled) &&
73
73
  (m = !0);
74
74
  let g = !1;
75
- null != (null === (r = a.dd) || void 0 === r ? void 0 : r.enabled) &&
76
- this.vd() !==
77
- (null === (o = a.dd) || void 0 === o ? void 0 : o.enabled) &&
75
+ null != (null === (r = a.vd) || void 0 === r ? void 0 : r.enabled) &&
76
+ this.md() !==
77
+ (null === (o = a.vd) || void 0 === o ? void 0 : o.enabled) &&
78
78
  (g = !0),
79
- (this.Zl = a),
80
- this.j.Pt(s.It.sd, a.qt()),
81
- h && this.Gl.A(),
82
- d && this._l.A(),
83
- c && this.Vl.A(),
84
- v && this.Jl.A(),
85
- m && this.Ql.A(),
86
- g && this.Wl.A();
79
+ (this.ed = a),
80
+ this.j.Pt(s.It.nd, a.qt()),
81
+ h && this._l.A(),
82
+ d && this.Vl.A(),
83
+ c && this.Jl.A(),
84
+ v && this.Ql.A(),
85
+ m && this.Wl.A(),
86
+ g && this.Yl.A();
87
87
  }
88
88
  }
89
89
  }
90
90
  xu(t) {
91
- const i = this.Gl.Ut(t);
92
- return this.Yl && this.Gl.removeSubscription(this.Yl), (this.Yl = i), i;
91
+ const i = this._l.Ut(t);
92
+ return this.Zl && this._l.removeSubscription(this.Zl), (this.Zl = i), i;
93
93
  }
94
94
  $i(t) {
95
- return this._l.Ut(t);
96
- }
97
- bo(t) {
98
95
  return this.Vl.Ut(t);
99
96
  }
100
- V(t) {
97
+ bo(t) {
101
98
  return this.Jl.Ut(t);
102
99
  }
103
- Tr(t) {
100
+ V(t) {
104
101
  return this.Ql.Ut(t);
105
102
  }
106
- md(t) {
103
+ Tr(t) {
107
104
  return this.Wl.Ut(t);
108
105
  }
106
+ gd(t) {
107
+ return this.Yl.Ut(t);
108
+ }
109
109
  $e(t) {
110
- return -1 !== this.ed().gd.indexOf(t);
110
+ return -1 !== this.sd().bd.indexOf(t);
111
111
  }
112
112
  qu(t) {
113
- return -1 !== this.ed().bd.indexOf(t);
113
+ return -1 !== this.sd().fd.indexOf(t);
114
114
  }
115
115
  $r(t) {
116
- return -1 !== this.ed().fd.indexOf(t);
116
+ return -1 !== this.sd().pd.indexOf(t);
117
117
  }
118
- pd() {
119
- return this.ed().Rd;
118
+ Rd() {
119
+ return this.sd().Cd;
120
120
  }
121
121
  ju() {
122
- return this.ed().ad;
122
+ return this.sd().hd;
123
123
  }
124
124
  Pi() {
125
- return this.ed().hd.enabled || !1;
125
+ return this.sd().dd.enabled || !1;
126
126
  }
127
- Cd() {
128
- const t = this.ed().ud;
127
+ Ed() {
128
+ const t = this.sd().ad;
129
129
  return !(!t || null == t.enabled) && t.enabled;
130
130
  }
131
- Ul() {
132
- if (!this.Cd()) return -1;
133
- const t = this.ed().ud;
131
+ xl() {
132
+ if (!this.Ed()) return -1;
133
+ const t = this.sd().ad;
134
134
  return null == t.capacity || t.capacity < 10 ? -1 : t.capacity;
135
135
  }
136
- xl() {
137
- if (!this.Cd()) return -1;
138
- const t = this.ed().ud;
136
+ Hl() {
137
+ if (!this.Ed()) return -1;
138
+ const t = this.sd().ad;
139
139
  return null == t.refill_rate || t.refill_rate <= 0 ? -1 : t.refill_rate;
140
140
  }
141
- Ed(t) {
142
- const i = this.ed().ud.endpoint_overrides;
141
+ wd(t) {
142
+ const i = this.sd().ad.endpoint_overrides;
143
143
  return null == i ? null : i[t];
144
144
  }
145
- Hl(t) {
146
- const i = this.Ed(t);
145
+ Ol(t) {
146
+ const i = this.wd(t);
147
147
  return null == i || isNaN(i.capacity) || i.capacity <= 0 ? -1 : i.capacity;
148
148
  }
149
- Ol(t) {
150
- const i = this.Ed(t);
149
+ Gl(t) {
150
+ const i = this.wd(t);
151
151
  return null == i || isNaN(i.refill_rate) || i.refill_rate <= 0
152
152
  ? -1
153
153
  : i.refill_rate;
154
154
  }
155
155
  lo() {
156
- return this.ed().Xr.enabled && null == this.Ro()
157
- ? (v.Dt(p.Ya, { e: "Missing feature flag refresh_rate_limit." }), !1)
158
- : this.ed().Xr.enabled || !1;
156
+ return this.sd().Xr.enabled && null == this.Ro()
157
+ ? (v.Dt(p.Qa, { e: "Missing feature flag refresh_rate_limit." }), !1)
158
+ : this.sd().Xr.enabled || !1;
159
159
  }
160
160
  Ro() {
161
- return this.ed().Xr.refresh_rate_limit;
161
+ return this.sd().Xr.refresh_rate_limit;
162
162
  }
163
163
  Ot() {
164
164
  var t;
165
165
  return (
166
- (null === (t = this.ed().banners) || void 0 === t ? void 0 : t.enabled) ||
166
+ (null === (t = this.sd().banners) || void 0 === t ? void 0 : t.enabled) ||
167
167
  null
168
168
  );
169
169
  }
170
170
  re() {
171
171
  var t;
172
172
  return (
173
- (null === (t = this.ed().banners) || void 0 === t
173
+ (null === (t = this.sd().banners) || void 0 === t
174
174
  ? void 0
175
175
  : t.max_placements) || 0
176
176
  );
@@ -178,7 +178,7 @@ export default class Yt {
178
178
  Gt() {
179
179
  var t;
180
180
  const i =
181
- null === (t = this.ed().banners) || void 0 === t
181
+ null === (t = this.sd().banners) || void 0 === t
182
182
  ? void 0
183
183
  : t.dismissals_cache_size;
184
184
  return null != i && "number" == typeof i && i > 0 ? i : u;
@@ -186,19 +186,19 @@ export default class Yt {
186
186
  fn() {
187
187
  var t;
188
188
  return (
189
- (null === (t = this.ed().dust) || void 0 === t ? void 0 : t.enabled) || !1
189
+ (null === (t = this.sd().dust) || void 0 === t ? void 0 : t.enabled) || !1
190
190
  );
191
191
  }
192
- vd() {
192
+ md() {
193
193
  var t;
194
194
  return (
195
- (null === (t = this.ed().dd) || void 0 === t ? void 0 : t.enabled) || !1
195
+ (null === (t = this.sd().vd) || void 0 === t ? void 0 : t.enabled) || !1
196
196
  );
197
197
  }
198
198
  vt() {
199
199
  var t;
200
200
  const i =
201
- null === (t = this.ed().wd) || void 0 === t
201
+ null === (t = this.sd().Bd) || void 0 === t
202
202
  ? void 0
203
203
  : t.min_sleep_duration_ms;
204
204
  return null != i ? i : d;
@@ -206,18 +206,18 @@ export default class Yt {
206
206
  gt() {
207
207
  var t;
208
208
  const i =
209
- null === (t = this.ed().wd) || void 0 === t ? void 0 : t.scale_factor;
209
+ null === (t = this.sd().Bd) || void 0 === t ? void 0 : t.scale_factor;
210
210
  return null != i ? i : m;
211
211
  }
212
212
  bt() {
213
213
  var t;
214
214
  const i =
215
- null === (t = this.ed().wd) || void 0 === t
215
+ null === (t = this.sd().Bd) || void 0 === t
216
216
  ? void 0
217
217
  : t.max_sleep_duration_ms;
218
218
  return null != i ? i : c;
219
219
  }
220
- Bd() {
221
- return this.ed().Td;
220
+ Td() {
221
+ return this.sd().yd;
222
222
  }
223
223
  }
@@ -17,7 +17,7 @@ export default class Xt {
17
17
  (this.j = s),
18
18
  (this.Ss = t),
19
19
  (this.h = i);
20
- const n = this.h.Bd();
20
+ const n = this.h.Td();
21
21
  (this.im = n ? 1e3 * n : ts),
22
22
  (null == e || isNaN(e)) && (e = 1800),
23
23
  e < this.im / 1e3 &&
@@ -42,7 +42,7 @@ export default class Xt {
42
42
  }
43
43
  am() {
44
44
  const t = new Date().valueOf(),
45
- i = this.h.pd();
45
+ i = this.h.Rd();
46
46
  if (null == i) return !1;
47
47
  const e = this.j.St(s.It.dm),
48
48
  n = null == e || t - e > 1e3 * i;
@@ -21,20 +21,20 @@ export const STORAGE_KEYS = {
21
21
  ZE: "ab.storage.events",
22
22
  $E: "ab.storage.attributes",
23
23
  tS: "ab.storage.attributes.anonymous_user",
24
- Ba: "ab.storage.device",
25
- Ka: "ab.storage.sdk_metadata",
26
- Pa: "ab.storage.session_id_for_cached_metadata",
24
+ Ha: "ab.storage.device",
25
+ Pa: "ab.storage.sdk_metadata",
26
+ Ua: "ab.storage.session_id_for_cached_metadata",
27
27
  Uu: "ab.storage.pushToken",
28
28
  eS: "ab.storage.cardImpressions",
29
- sd: "ab.storage.serverConfig",
29
+ nd: "ab.storage.serverConfig",
30
30
  sS: "ab.storage.triggers",
31
31
  rS: "ab.storage.triggers.ts",
32
32
  dm: "ab.storage.messagingSessionStart",
33
33
  bi: "ab.storage.cc",
34
34
  ji: "ab.storage.ccLastFullSync",
35
35
  yi: "ab.storage.ccLastCardUpdated",
36
- Ml: "ab.storage.globalRateLimitCurrentTokenCount",
37
- Ll: "ab.storage.dynamicRateLimitCurrentTokenCount",
36
+ Xl: "ab.storage.globalRateLimitCurrentTokenCount",
37
+ El: "ab.storage.dynamicRateLimitCurrentTokenCount",
38
38
  Zt: "ab.storage.ccClicks",
39
39
  ps: "ab.storage.ccImpressions",
40
40
  fs: "ab.storage.ccDismissals",
@@ -51,7 +51,7 @@ export const STORAGE_KEYS = {
51
51
  ES: "ab.storage.lastReqToEndpoint",
52
52
  SS: "ab.storage.requestAttempts",
53
53
  pa: "ab.storage.deferredIam",
54
- Bl: "ab.storage.lastSdkReq",
54
+ Sl: "ab.storage.lastSdkReq",
55
55
  lS: "ab.storage.alias",
56
56
  Tt: "ab.storage.banners",
57
57
  At: "ab.storage.banners.impressions",
@@ -144,7 +144,7 @@ export default class ne {
144
144
  typeof t +
145
145
  ": " +
146
146
  JSON.stringify(t)),
147
- e.push(new Ie(null, p.Ya, new Date().valueOf(), null, { e: o }));
147
+ e.push(new Ie(null, p.Qa, new Date().valueOf(), null, { e: o }));
148
148
  }
149
149
  return e;
150
150
  }
@@ -193,7 +193,7 @@ export default class ne {
193
193
  gS(t) {
194
194
  return t || STORAGE_KEYS.It.tS;
195
195
  }
196
- vl(t) {
196
+ Rl(t) {
197
197
  let e = this.uS.wr(STORAGE_KEYS.It.$E);
198
198
  null == e && (e = {});
199
199
  const s = this.gS(t[User.Sa]),
@@ -232,7 +232,7 @@ export default class ne {
232
232
  ((e[s] = void 0),
233
233
  this.uS.store(STORAGE_KEYS.It.$E, e),
234
234
  (r[User.Sa] = t),
235
- this.vl(r));
235
+ this.Rl(r));
236
236
  }
237
237
  const s = this.$u(STORAGE_KEYS.Ou.um);
238
238
  let r = null;
@@ -1,8 +1,8 @@
1
1
  export default {
2
- Va: "invalid_api_key",
3
- Za: "blacklisted",
4
- dl: "no_device_identifier",
5
- Qa: "invalid_json_response",
6
- Wa: "empty_response",
2
+ Za: "invalid_api_key",
3
+ dl: "blacklisted",
4
+ fl: "no_device_identifier",
5
+ Va: "invalid_json_response",
6
+ Ya: "empty_response",
7
7
  __: "sdk_auth_error",
8
8
  };