@firebase/firestore 4.3.2-canary.bebecdaad → 4.3.2-canary.e9ff107ee

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/dist/index.cjs.js CHANGED
@@ -8,7 +8,7 @@ var logger = require('@firebase/logger');
8
8
  var util = require('@firebase/util');
9
9
  var webchannelWrapper = require('@firebase/webchannel-wrapper');
10
10
 
11
- const S = "@firebase/firestore";
11
+ const w = "@firebase/firestore";
12
12
 
13
13
  /**
14
14
  * @license
@@ -70,7 +70,7 @@ User.MOCK_USER = new User("mock-user");
70
70
  * See the License for the specific language governing permissions and
71
71
  * limitations under the License.
72
72
  */
73
- let b = "10.6.0-canary.bebecdaad";
73
+ let S = "10.6.0-canary.e9ff107ee";
74
74
 
75
75
  /**
76
76
  * @license
@@ -88,11 +88,11 @@ let b = "10.6.0-canary.bebecdaad";
88
88
  * See the License for the specific language governing permissions and
89
89
  * limitations under the License.
90
90
  */
91
- const D = new logger.Logger("@firebase/firestore");
91
+ const b = new logger.Logger("@firebase/firestore");
92
92
 
93
93
  // Helper methods are needed because variables can't be exported as read/write
94
94
  function __PRIVATE_getLogLevel() {
95
- return D.logLevel;
95
+ return b.logLevel;
96
96
  }
97
97
 
98
98
  /**
@@ -108,29 +108,29 @@ function __PRIVATE_getLogLevel() {
108
108
  * <li><code>`silent` to turn off logging.</li>
109
109
  * </ul>
110
110
  */ function setLogLevel(e) {
111
- D.setLogLevel(e);
111
+ b.setLogLevel(e);
112
112
  }
113
113
 
114
114
  function __PRIVATE_logDebug(e, ...t) {
115
- if (D.logLevel <= logger.LogLevel.DEBUG) {
115
+ if (b.logLevel <= logger.LogLevel.DEBUG) {
116
116
  const n = t.map(__PRIVATE_argToString);
117
- D.debug(`Firestore (${b}): ${e}`, ...n);
117
+ b.debug(`Firestore (${S}): ${e}`, ...n);
118
118
  }
119
119
  }
120
120
 
121
121
  function __PRIVATE_logError(e, ...t) {
122
- if (D.logLevel <= logger.LogLevel.ERROR) {
122
+ if (b.logLevel <= logger.LogLevel.ERROR) {
123
123
  const n = t.map(__PRIVATE_argToString);
124
- D.error(`Firestore (${b}): ${e}`, ...n);
124
+ b.error(`Firestore (${S}): ${e}`, ...n);
125
125
  }
126
126
  }
127
127
 
128
128
  /**
129
129
  * @internal
130
130
  */ function __PRIVATE_logWarn(e, ...t) {
131
- if (D.logLevel <= logger.LogLevel.WARN) {
131
+ if (b.logLevel <= logger.LogLevel.WARN) {
132
132
  const n = t.map(__PRIVATE_argToString);
133
- D.warn(`Firestore (${b}): ${e}`, ...n);
133
+ b.warn(`Firestore (${S}): ${e}`, ...n);
134
134
  }
135
135
  }
136
136
 
@@ -191,7 +191,7 @@ function __PRIVATE_logError(e, ...t) {
191
191
  */ function fail(e = "Unexpected state") {
192
192
  // Log the failure in addition to throw an exception, just in case the
193
193
  // exception is swallowed.
194
- const t = `FIRESTORE (${b}) INTERNAL ASSERTION FAILED: ` + e;
194
+ const t = `FIRESTORE (${S}) INTERNAL ASSERTION FAILED: ` + e;
195
195
  // NOTE: We don't use FirestoreError here because these are internal failures
196
196
  // that cannot be handled by the user. (Also it would create a circular
197
197
  // dependency between the error and assert modules which doesn't work.)
@@ -244,7 +244,7 @@ t) {
244
244
  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
245
245
  * See the License for the specific language governing permissions and
246
246
  * limitations under the License.
247
- */ const C = {
247
+ */ const D = {
248
248
  // Causes are copied from:
249
249
  // https://github.com/grpc/grpc/blob/bceec94ea4fc5f0085d81235d8e1c06798dc341a/include/grpc%2B%2B/impl/codegen/status_code_enum.h
250
250
  /** Not an error; returned on success. */
@@ -789,11 +789,11 @@ class Timestamp {
789
789
  * The fractions of a second at nanosecond resolution.*
790
790
  */
791
791
  t) {
792
- if (this.seconds = e, this.nanoseconds = t, t < 0) throw new FirestoreError(C.INVALID_ARGUMENT, "Timestamp nanoseconds out of range: " + t);
793
- if (t >= 1e9) throw new FirestoreError(C.INVALID_ARGUMENT, "Timestamp nanoseconds out of range: " + t);
794
- if (e < -62135596800) throw new FirestoreError(C.INVALID_ARGUMENT, "Timestamp seconds out of range: " + e);
792
+ if (this.seconds = e, this.nanoseconds = t, t < 0) throw new FirestoreError(D.INVALID_ARGUMENT, "Timestamp nanoseconds out of range: " + t);
793
+ if (t >= 1e9) throw new FirestoreError(D.INVALID_ARGUMENT, "Timestamp nanoseconds out of range: " + t);
794
+ if (e < -62135596800) throw new FirestoreError(D.INVALID_ARGUMENT, "Timestamp seconds out of range: " + e);
795
795
  // This will break in the year 10,000.
796
- if (e >= 253402300800) throw new FirestoreError(C.INVALID_ARGUMENT, "Timestamp seconds out of range: " + e);
796
+ if (e >= 253402300800) throw new FirestoreError(D.INVALID_ARGUMENT, "Timestamp seconds out of range: " + e);
797
797
  }
798
798
  /**
799
799
  * Creates a new timestamp with the current date, with millisecond precision.
@@ -1041,7 +1041,7 @@ class BasePath {
1041
1041
  // for legacy reasons and should not be used frequently).
1042
1042
  const t = [];
1043
1043
  for (const n of e) {
1044
- if (n.indexOf("//") >= 0) throw new FirestoreError(C.INVALID_ARGUMENT, `Invalid segment (${n}). Paths must not contain // in them.`);
1044
+ if (n.indexOf("//") >= 0) throw new FirestoreError(D.INVALID_ARGUMENT, `Invalid segment (${n}). Paths must not contain // in them.`);
1045
1045
  // Strip leading and traling slashed.
1046
1046
  t.push(...n.split("/").filter((e => e.length > 0)));
1047
1047
  }
@@ -1052,7 +1052,7 @@ class BasePath {
1052
1052
  }
1053
1053
  }
1054
1054
 
1055
- const v = /^[_a-zA-Z][_a-zA-Z0-9]*$/;
1055
+ const C = /^[_a-zA-Z][_a-zA-Z0-9]*$/;
1056
1056
 
1057
1057
  /**
1058
1058
  * A dot-separated path for navigating sub-objects within a document.
@@ -1065,7 +1065,7 @@ const v = /^[_a-zA-Z][_a-zA-Z0-9]*$/;
1065
1065
  * Returns true if the string could be used as a segment in a field path
1066
1066
  * without escaping.
1067
1067
  */ static isValidIdentifier(e) {
1068
- return v.test(e);
1068
+ return C.test(e);
1069
1069
  }
1070
1070
  canonicalString() {
1071
1071
  return this.toArray().map((e => (e = e.replace(/\\/g, "\\\\").replace(/`/g, "\\`"),
@@ -1097,21 +1097,21 @@ const v = /^[_a-zA-Z][_a-zA-Z0-9]*$/;
1097
1097
  const t = [];
1098
1098
  let n = "", r = 0;
1099
1099
  const __PRIVATE_addCurrentSegment = () => {
1100
- if (0 === n.length) throw new FirestoreError(C.INVALID_ARGUMENT, `Invalid field path (${e}). Paths must not be empty, begin with '.', end with '.', or contain '..'`);
1100
+ if (0 === n.length) throw new FirestoreError(D.INVALID_ARGUMENT, `Invalid field path (${e}). Paths must not be empty, begin with '.', end with '.', or contain '..'`);
1101
1101
  t.push(n), n = "";
1102
1102
  };
1103
1103
  let i = !1;
1104
1104
  for (;r < e.length; ) {
1105
1105
  const t = e[r];
1106
1106
  if ("\\" === t) {
1107
- if (r + 1 === e.length) throw new FirestoreError(C.INVALID_ARGUMENT, "Path has trailing escape character: " + e);
1107
+ if (r + 1 === e.length) throw new FirestoreError(D.INVALID_ARGUMENT, "Path has trailing escape character: " + e);
1108
1108
  const t = e[r + 1];
1109
- if ("\\" !== t && "." !== t && "`" !== t) throw new FirestoreError(C.INVALID_ARGUMENT, "Path has invalid escape sequence: " + e);
1109
+ if ("\\" !== t && "." !== t && "`" !== t) throw new FirestoreError(D.INVALID_ARGUMENT, "Path has invalid escape sequence: " + e);
1110
1110
  n += t, r += 2;
1111
1111
  } else "`" === t ? (i = !i, r++) : "." !== t || i ? (n += t, r++) : (__PRIVATE_addCurrentSegment(),
1112
1112
  r++);
1113
1113
  }
1114
- if (__PRIVATE_addCurrentSegment(), i) throw new FirestoreError(C.INVALID_ARGUMENT, "Unterminated ` in path: " + e);
1114
+ if (__PRIVATE_addCurrentSegment(), i) throw new FirestoreError(D.INVALID_ARGUMENT, "Unterminated ` in path: " + e);
1115
1115
  return new FieldPath$1(t);
1116
1116
  }
1117
1117
  static emptyPath() {
@@ -1363,7 +1363,7 @@ function __PRIVATE_indexOffsetComparator(e, t) {
1363
1363
  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
1364
1364
  * See the License for the specific language governing permissions and
1365
1365
  * limitations under the License.
1366
- */ const F = "The current tab is not in the required state to perform this operation. It might be necessary to refresh the browser tab.";
1366
+ */ const v = "The current tab is not in the required state to perform this operation. It might be necessary to refresh the browser tab.";
1367
1367
 
1368
1368
  /**
1369
1369
  * A base class representing a persistence transaction, encapsulating both the
@@ -1410,7 +1410,7 @@ function __PRIVATE_indexOffsetComparator(e, t) {
1410
1410
  * @param err - An error returned by a LocalStore operation.
1411
1411
  * @returns A Promise that resolves after we recovered, or the original error.
1412
1412
  */ async function __PRIVATE_ignoreIfPrimaryLeaseLoss(e) {
1413
- if (e.code !== C.FAILED_PRECONDITION || e.message !== F) throw e;
1413
+ if (e.code !== D.FAILED_PRECONDITION || e.message !== v) throw e;
1414
1414
  __PRIVATE_logDebug("LocalStore", "Unexpectedly lost primary lease");
1415
1415
  }
1416
1416
 
@@ -1721,7 +1721,7 @@ class __PRIVATE_SimpleDbTransaction {
1721
1721
  n(new __PRIVATE_IndexedDbTransactionError(e, "Cannot upgrade IndexedDB schema while another tab is open. Close all tabs that access Firestore and reload this page to proceed."));
1722
1722
  }, r.onerror = t => {
1723
1723
  const r = t.target.error;
1724
- "VersionError" === r.name ? n(new FirestoreError(C.FAILED_PRECONDITION, "A newer version of the Firestore SDK was previously used and so the persisted data is not compatible with the version of the SDK you are now using. The SDK will operate with persistence disabled. If you need persistence, please re-upgrade to a newer version of the SDK or else clear the persisted IndexedDB data for your app to start fresh.")) : "InvalidStateError" === r.name ? n(new FirestoreError(C.FAILED_PRECONDITION, "Unable to open an IndexedDB connection. This could be due to running in a private browsing session on a browser whose private browsing sessions do not support IndexedDB: " + r)) : n(new __PRIVATE_IndexedDbTransactionError(e, r));
1724
+ "VersionError" === r.name ? n(new FirestoreError(D.FAILED_PRECONDITION, "A newer version of the Firestore SDK was previously used and so the persisted data is not compatible with the version of the SDK you are now using. The SDK will operate with persistence disabled. If you need persistence, please re-upgrade to a newer version of the SDK or else clear the persisted IndexedDB data for your app to start fresh.")) : "InvalidStateError" === r.name ? n(new FirestoreError(D.FAILED_PRECONDITION, "Unable to open an IndexedDB connection. This could be due to running in a private browsing session on a browser whose private browsing sessions do not support IndexedDB: " + r)) : n(new __PRIVATE_IndexedDbTransactionError(e, r));
1725
1725
  }, r.onupgradeneeded = e => {
1726
1726
  __PRIVATE_logDebug("SimpleDb", 'Database "' + this.name + '" requires upgrade from version:', e.oldVersion);
1727
1727
  const t = e.target.result;
@@ -1808,7 +1808,7 @@ class __PRIVATE_SimpleDbTransaction {
1808
1808
 
1809
1809
  /** An error that wraps exceptions that thrown during IndexedDB execution. */ class __PRIVATE_IndexedDbTransactionError extends FirestoreError {
1810
1810
  constructor(e, t) {
1811
- super(C.UNAVAILABLE, `IndexedDB transaction '${e}' failed: ${t}`), this.name = "IndexedDbTransactionError";
1811
+ super(D.UNAVAILABLE, `IndexedDB transaction '${e}' failed: ${t}`), this.name = "IndexedDbTransactionError";
1812
1812
  }
1813
1813
  }
1814
1814
 
@@ -1992,7 +1992,7 @@ class __PRIVATE_SimpleDbTransaction {
1992
1992
  }
1993
1993
 
1994
1994
  // Guard so we only report the error once.
1995
- let M = !1;
1995
+ let F = !1;
1996
1996
 
1997
1997
  function __PRIVATE_checkForAndReportiOSError(e) {
1998
1998
  const t = __PRIVATE_SimpleDb.S(util.getUA());
@@ -2001,7 +2001,7 @@ function __PRIVATE_checkForAndReportiOSError(e) {
2001
2001
  if (e.message.indexOf(t) >= 0) {
2002
2002
  // Wrap error in a more descriptive one.
2003
2003
  const e = new FirestoreError("internal", `IOS_INDEXEDDB_BUG1: IndexedDb has thrown '${t}'. This is likely due to an unavoidable bug in iOS. See https://stackoverflow.com/q/56496296/110915 for details and a potential workaround.`);
2004
- return M || (M = !0,
2004
+ return F || (F = !0,
2005
2005
  // Throw a global exception outside of this promise chain, for the user to
2006
2006
  // potentially catch.
2007
2007
  setTimeout((() => {
@@ -2253,7 +2253,7 @@ function __PRIVATE_encodeResourcePath(e) {
2253
2253
  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
2254
2254
  * See the License for the specific language governing permissions and
2255
2255
  * limitations under the License.
2256
- */ const x = [ "userId", "batchId" ];
2256
+ */ const M = [ "userId", "batchId" ];
2257
2257
 
2258
2258
  /**
2259
2259
  * @license
@@ -2298,7 +2298,7 @@ function __PRIVATE_newDbDocumentMutationPrefixForPath(e, t) {
2298
2298
  * there is no useful information to store as the value. The raw (unencoded)
2299
2299
  * path cannot be stored because IndexedDb doesn't store prototype
2300
2300
  * information.
2301
- */ const O = {}, N = [ "prefixPath", "collectionGroup", "readTime", "documentId" ], B = [ "prefixPath", "collectionGroup", "documentId" ], L = [ "collectionGroup", "readTime", "prefixPath", "documentId" ], k = [ "canonicalId", "targetId" ], q = [ "targetId", "path" ], Q = [ "path", "targetId" ], K = [ "collectionId", "parent" ], $ = [ "indexId", "uid" ], U = [ "uid", "sequenceNumber" ], W = [ "indexId", "uid", "arrayValue", "directionalValue", "orderedDocumentKey", "documentKey" ], G = [ "indexId", "uid", "orderedDocumentKey" ], z = [ "userId", "collectionPath", "documentId" ], j = [ "userId", "collectionPath", "largestBatchId" ], H = [ "userId", "collectionGroup", "largestBatchId" ], J = [ ...[ ...[ ...[ ...[ "mutationQueues", "mutations", "documentMutations", "remoteDocuments", "targets", "owner", "targetGlobal", "targetDocuments" ], "clientMetadata" ], "remoteDocumentGlobal" ], "collectionParents" ], "bundles", "namedQueries" ], Y = [ ...J, "documentOverlays" ], Z = [ "mutationQueues", "mutations", "documentMutations", "remoteDocumentsV14", "targets", "owner", "targetGlobal", "targetDocuments", "clientMetadata", "remoteDocumentGlobal", "collectionParents", "bundles", "namedQueries", "documentOverlays" ], X = Z, ee = [ ...X, "indexConfiguration", "indexState", "indexEntries" ];
2301
+ */ const x = {}, O = [ "prefixPath", "collectionGroup", "readTime", "documentId" ], N = [ "prefixPath", "collectionGroup", "documentId" ], B = [ "collectionGroup", "readTime", "prefixPath", "documentId" ], L = [ "canonicalId", "targetId" ], k = [ "targetId", "path" ], q = [ "path", "targetId" ], Q = [ "collectionId", "parent" ], K = [ "indexId", "uid" ], $ = [ "uid", "sequenceNumber" ], U = [ "indexId", "uid", "arrayValue", "directionalValue", "orderedDocumentKey", "documentKey" ], W = [ "indexId", "uid", "orderedDocumentKey" ], G = [ "userId", "collectionPath", "documentId" ], z = [ "userId", "collectionPath", "largestBatchId" ], j = [ "userId", "collectionGroup", "largestBatchId" ], H = [ ...[ ...[ ...[ ...[ "mutationQueues", "mutations", "documentMutations", "remoteDocuments", "targets", "owner", "targetGlobal", "targetDocuments" ], "clientMetadata" ], "remoteDocumentGlobal" ], "collectionParents" ], "bundles", "namedQueries" ], J = [ ...H, "documentOverlays" ], Y = [ "mutationQueues", "mutations", "documentMutations", "remoteDocumentsV14", "targets", "owner", "targetGlobal", "targetDocuments", "clientMetadata", "remoteDocumentGlobal", "collectionParents", "bundles", "namedQueries", "documentOverlays" ], Z = Y, X = [ ...Z, "indexConfiguration", "indexState", "indexEntries" ];
2302
2302
 
2303
2303
  /**
2304
2304
  * @license
@@ -3055,7 +3055,7 @@ function __PRIVATE_isBase64Available() {
3055
3055
 
3056
3056
  ByteString.EMPTY_BYTE_STRING = new ByteString("");
3057
3057
 
3058
- const te = new RegExp(/^\d{4}-\d\d-\d\dT\d\d:\d\d:\d\d(?:\.(\d+))?Z$/);
3058
+ const ee = new RegExp(/^\d{4}-\d\d-\d\dT\d\d:\d\d:\d\d(?:\.(\d+))?Z$/);
3059
3059
 
3060
3060
  /**
3061
3061
  * Converts the possible Proto values for a timestamp value into a "seconds and
@@ -3069,7 +3069,7 @@ const te = new RegExp(/^\d{4}-\d\d-\d\dT\d\d:\d\d:\d\d(?:\.(\d+))?Z$/);
3069
3069
  // (millis), so we do some custom parsing here.
3070
3070
  // Parse the nanos right out of the string.
3071
3071
  let t = 0;
3072
- const n = te.exec(e);
3072
+ const n = ee.exec(e);
3073
3073
  if (__PRIVATE_hardAssert(!!n), n[1]) {
3074
3074
  // Pad the fraction out to 9 digits (nanos).
3075
3075
  let e = n[1];
@@ -3236,7 +3236,7 @@ class DatabaseId {
3236
3236
  * See the License for the specific language governing permissions and
3237
3237
  * limitations under the License.
3238
3238
  */
3239
- const ne = {
3239
+ const te = {
3240
3240
  mapValue: {
3241
3241
  fields: {
3242
3242
  __type__: {
@@ -3244,7 +3244,7 @@ const ne = {
3244
3244
  }
3245
3245
  }
3246
3246
  }
3247
- }, re = {
3247
+ }, ne = {
3248
3248
  nullValue: "NULL_VALUE"
3249
3249
  };
3250
3250
 
@@ -3388,9 +3388,9 @@ function __PRIVATE_valueCompare(e, t) {
3388
3388
 
3389
3389
  case 10 /* TypeOrder.ObjectValue */ :
3390
3390
  return function __PRIVATE_compareMaps(e, t) {
3391
- if (e === ne.mapValue && t === ne.mapValue) return 0;
3392
- if (e === ne.mapValue) return 1;
3393
- if (t === ne.mapValue) return -1;
3391
+ if (e === te.mapValue && t === te.mapValue) return 0;
3392
+ if (e === te.mapValue) return 1;
3393
+ if (t === te.mapValue) return -1;
3394
3394
  const n = e.fields || {}, r = Object.keys(n), i = t.fields || {}, s = Object.keys(i);
3395
3395
  // Even though MapValues are likely sorted correctly based on their insertion
3396
3396
  // order (e.g. when received from the backend), local modifications can bring
@@ -3566,7 +3566,7 @@ function isArray(e) {
3566
3566
  }
3567
3567
 
3568
3568
  /** Returns the lowest value for the given value type (inclusive). */ function __PRIVATE_valuesGetLowerBound(e) {
3569
- return "nullValue" in e ? re : "booleanValue" in e ? {
3569
+ return "nullValue" in e ? ne : "booleanValue" in e ? {
3570
3570
  booleanValue: !1
3571
3571
  } : "integerValue" in e || "doubleValue" in e ? {
3572
3572
  doubleValue: NaN
@@ -3612,7 +3612,7 @@ function isArray(e) {
3612
3612
  arrayValue: {}
3613
3613
  } : "arrayValue" in e ? {
3614
3614
  mapValue: {}
3615
- } : "mapValue" in e ? ne : fail();
3615
+ } : "mapValue" in e ? te : fail();
3616
3616
  }
3617
3617
 
3618
3618
  function __PRIVATE_lowerBoundCompare(e, t) {
@@ -4300,10 +4300,10 @@ function __PRIVATE_targetIsDocumentTarget(e) {
4300
4300
  * the provided `fieldPath` (or the upper bound for an descending segment).
4301
4301
  */
4302
4302
  function __PRIVATE_targetGetAscendingBound(e, t, n) {
4303
- let r = re, i = !0;
4303
+ let r = ne, i = !0;
4304
4304
  // Process all filters to find a value for the current field segment
4305
4305
  for (const n of __PRIVATE_targetGetFieldFiltersForPath(e, t)) {
4306
- let e = re, t = !0;
4306
+ let e = ne, t = !0;
4307
4307
  switch (n.op) {
4308
4308
  case "<" /* Operator.LESS_THAN */ :
4309
4309
  case "<=" /* Operator.LESS_THAN_OR_EQUAL */ :
@@ -4322,7 +4322,7 @@ function __PRIVATE_targetGetAscendingBound(e, t, n) {
4322
4322
 
4323
4323
  case "!=" /* Operator.NOT_EQUAL */ :
4324
4324
  case "not-in" /* Operator.NOT_IN */ :
4325
- e = re;
4325
+ e = ne;
4326
4326
  // Remaining filters cannot be used as lower bounds.
4327
4327
  }
4328
4328
  __PRIVATE_lowerBoundCompare({
@@ -4358,10 +4358,10 @@ function __PRIVATE_targetGetAscendingBound(e, t, n) {
4358
4358
  * Returns the value to use as the upper bound for ascending index segment at
4359
4359
  * the provided `fieldPath` (or the lower bound for a descending segment).
4360
4360
  */ function __PRIVATE_targetGetDescendingBound(e, t, n) {
4361
- let r = ne, i = !0;
4361
+ let r = te, i = !0;
4362
4362
  // Process all filters to find a value for the current field segment
4363
4363
  for (const n of __PRIVATE_targetGetFieldFiltersForPath(e, t)) {
4364
- let e = ne, t = !0;
4364
+ let e = te, t = !0;
4365
4365
  switch (n.op) {
4366
4366
  case ">=" /* Operator.GREATER_THAN_OR_EQUAL */ :
4367
4367
  case ">" /* Operator.GREATER_THAN */ :
@@ -4380,7 +4380,7 @@ function __PRIVATE_targetGetAscendingBound(e, t, n) {
4380
4380
 
4381
4381
  case "!=" /* Operator.NOT_EQUAL */ :
4382
4382
  case "not-in" /* Operator.NOT_IN */ :
4383
- e = ne;
4383
+ e = te;
4384
4384
  // Remaining filters cannot be used as upper bounds.
4385
4385
  }
4386
4386
  __PRIVATE_upperBoundCompare({
@@ -4757,22 +4757,22 @@ function __PRIVATE_compareDocs(e, t, n) {
4757
4757
  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
4758
4758
  * See the License for the specific language governing permissions and
4759
4759
  * limitations under the License.
4760
- */ const ie = new SortedMap(DocumentKey.comparator);
4760
+ */ const re = new SortedMap(DocumentKey.comparator);
4761
4761
 
4762
4762
  function __PRIVATE_mutableDocumentMap() {
4763
- return ie;
4763
+ return re;
4764
4764
  }
4765
4765
 
4766
- const se = new SortedMap(DocumentKey.comparator);
4766
+ const ie = new SortedMap(DocumentKey.comparator);
4767
4767
 
4768
4768
  function documentMap(...e) {
4769
- let t = se;
4769
+ let t = ie;
4770
4770
  for (const n of e) t = t.insert(n.key, n);
4771
4771
  return t;
4772
4772
  }
4773
4773
 
4774
4774
  function __PRIVATE_convertOverlayedDocumentMapToDocumentMap(e) {
4775
- let t = se;
4775
+ let t = ie;
4776
4776
  return e.forEach(((e, n) => t = t.insert(e, n.overlayedDocument))), t;
4777
4777
  }
4778
4778
 
@@ -4788,20 +4788,20 @@ function __PRIVATE_newDocumentKeyMap() {
4788
4788
  return new ObjectMap((e => e.toString()), ((e, t) => e.isEqual(t)));
4789
4789
  }
4790
4790
 
4791
- const oe = new SortedMap(DocumentKey.comparator);
4791
+ const se = new SortedMap(DocumentKey.comparator);
4792
4792
 
4793
- const _e = new SortedSet(DocumentKey.comparator);
4793
+ const oe = new SortedSet(DocumentKey.comparator);
4794
4794
 
4795
4795
  function __PRIVATE_documentKeySet(...e) {
4796
- let t = _e;
4796
+ let t = oe;
4797
4797
  for (const n of e) t = t.add(n);
4798
4798
  return t;
4799
4799
  }
4800
4800
 
4801
- const ae = new SortedSet(__PRIVATE_primitiveComparator);
4801
+ const _e = new SortedSet(__PRIVATE_primitiveComparator);
4802
4802
 
4803
4803
  function __PRIVATE_targetIdSet() {
4804
- return ae;
4804
+ return _e;
4805
4805
  }
4806
4806
 
4807
4807
  /**
@@ -5492,7 +5492,7 @@ class __PRIVATE_VerifyMutation extends Mutation {
5492
5492
  */ static from(e, t, n) {
5493
5493
  __PRIVATE_hardAssert(e.mutations.length === n.length);
5494
5494
  let r = function __PRIVATE_documentVersionMap() {
5495
- return oe;
5495
+ return se;
5496
5496
  }();
5497
5497
  const i = e.mutations;
5498
5498
  for (let e = 0; e < i.length; e++) r = r.insert(i[e].key, n[e].version);
@@ -5606,7 +5606,7 @@ class __PRIVATE_VerifyMutation extends Mutation {
5606
5606
  * Important! The names of these identifiers matter because the string forms
5607
5607
  * are used for reverse lookups from the webchannel stream. Do NOT change the
5608
5608
  * names of these identifiers or change this into a const enum.
5609
- */ var ue, ce;
5609
+ */ var ae, ue;
5610
5610
 
5611
5611
  /**
5612
5612
  * Determines whether an error code represents a permanent error when received
@@ -5619,29 +5619,29 @@ function __PRIVATE_isPermanentError(e) {
5619
5619
  default:
5620
5620
  return fail();
5621
5621
 
5622
- case C.CANCELLED:
5623
- case C.UNKNOWN:
5624
- case C.DEADLINE_EXCEEDED:
5625
- case C.RESOURCE_EXHAUSTED:
5626
- case C.INTERNAL:
5627
- case C.UNAVAILABLE:
5622
+ case D.CANCELLED:
5623
+ case D.UNKNOWN:
5624
+ case D.DEADLINE_EXCEEDED:
5625
+ case D.RESOURCE_EXHAUSTED:
5626
+ case D.INTERNAL:
5627
+ case D.UNAVAILABLE:
5628
5628
  // Unauthenticated means something went wrong with our token and we need
5629
5629
  // to retry with new credentials which will happen automatically.
5630
- case C.UNAUTHENTICATED:
5630
+ case D.UNAUTHENTICATED:
5631
5631
  return !1;
5632
5632
 
5633
- case C.INVALID_ARGUMENT:
5634
- case C.NOT_FOUND:
5635
- case C.ALREADY_EXISTS:
5636
- case C.PERMISSION_DENIED:
5637
- case C.FAILED_PRECONDITION:
5633
+ case D.INVALID_ARGUMENT:
5634
+ case D.NOT_FOUND:
5635
+ case D.ALREADY_EXISTS:
5636
+ case D.PERMISSION_DENIED:
5637
+ case D.FAILED_PRECONDITION:
5638
5638
  // Aborted might be retried in some scenarios, but that is dependant on
5639
5639
  // the context and should handled individually by the calling code.
5640
5640
  // See https://cloud.google.com/apis/design/errors.
5641
- case C.ABORTED:
5642
- case C.OUT_OF_RANGE:
5643
- case C.UNIMPLEMENTED:
5644
- case C.DATA_LOSS:
5641
+ case D.ABORTED:
5642
+ case D.OUT_OF_RANGE:
5643
+ case D.UNIMPLEMENTED:
5644
+ case D.DATA_LOSS:
5645
5645
  return !0;
5646
5646
  }
5647
5647
  }
@@ -5669,58 +5669,58 @@ function __PRIVATE_mapCodeFromRpcCode(e) {
5669
5669
  if (void 0 === e)
5670
5670
  // This shouldn't normally happen, but in certain error cases (like trying
5671
5671
  // to send invalid proto messages) we may get an error with no GRPC code.
5672
- return __PRIVATE_logError("GRPC error has no .code"), C.UNKNOWN;
5672
+ return __PRIVATE_logError("GRPC error has no .code"), D.UNKNOWN;
5673
5673
  switch (e) {
5674
- case ue.OK:
5675
- return C.OK;
5674
+ case ae.OK:
5675
+ return D.OK;
5676
5676
 
5677
- case ue.CANCELLED:
5678
- return C.CANCELLED;
5677
+ case ae.CANCELLED:
5678
+ return D.CANCELLED;
5679
5679
 
5680
- case ue.UNKNOWN:
5681
- return C.UNKNOWN;
5680
+ case ae.UNKNOWN:
5681
+ return D.UNKNOWN;
5682
5682
 
5683
- case ue.DEADLINE_EXCEEDED:
5684
- return C.DEADLINE_EXCEEDED;
5683
+ case ae.DEADLINE_EXCEEDED:
5684
+ return D.DEADLINE_EXCEEDED;
5685
5685
 
5686
- case ue.RESOURCE_EXHAUSTED:
5687
- return C.RESOURCE_EXHAUSTED;
5686
+ case ae.RESOURCE_EXHAUSTED:
5687
+ return D.RESOURCE_EXHAUSTED;
5688
5688
 
5689
- case ue.INTERNAL:
5690
- return C.INTERNAL;
5689
+ case ae.INTERNAL:
5690
+ return D.INTERNAL;
5691
5691
 
5692
- case ue.UNAVAILABLE:
5693
- return C.UNAVAILABLE;
5692
+ case ae.UNAVAILABLE:
5693
+ return D.UNAVAILABLE;
5694
5694
 
5695
- case ue.UNAUTHENTICATED:
5696
- return C.UNAUTHENTICATED;
5695
+ case ae.UNAUTHENTICATED:
5696
+ return D.UNAUTHENTICATED;
5697
5697
 
5698
- case ue.INVALID_ARGUMENT:
5699
- return C.INVALID_ARGUMENT;
5698
+ case ae.INVALID_ARGUMENT:
5699
+ return D.INVALID_ARGUMENT;
5700
5700
 
5701
- case ue.NOT_FOUND:
5702
- return C.NOT_FOUND;
5701
+ case ae.NOT_FOUND:
5702
+ return D.NOT_FOUND;
5703
5703
 
5704
- case ue.ALREADY_EXISTS:
5705
- return C.ALREADY_EXISTS;
5704
+ case ae.ALREADY_EXISTS:
5705
+ return D.ALREADY_EXISTS;
5706
5706
 
5707
- case ue.PERMISSION_DENIED:
5708
- return C.PERMISSION_DENIED;
5707
+ case ae.PERMISSION_DENIED:
5708
+ return D.PERMISSION_DENIED;
5709
5709
 
5710
- case ue.FAILED_PRECONDITION:
5711
- return C.FAILED_PRECONDITION;
5710
+ case ae.FAILED_PRECONDITION:
5711
+ return D.FAILED_PRECONDITION;
5712
5712
 
5713
- case ue.ABORTED:
5714
- return C.ABORTED;
5713
+ case ae.ABORTED:
5714
+ return D.ABORTED;
5715
5715
 
5716
- case ue.OUT_OF_RANGE:
5717
- return C.OUT_OF_RANGE;
5716
+ case ae.OUT_OF_RANGE:
5717
+ return D.OUT_OF_RANGE;
5718
5718
 
5719
- case ue.UNIMPLEMENTED:
5720
- return C.UNIMPLEMENTED;
5719
+ case ae.UNIMPLEMENTED:
5720
+ return D.UNIMPLEMENTED;
5721
5721
 
5722
- case ue.DATA_LOSS:
5723
- return C.DATA_LOSS;
5722
+ case ae.DATA_LOSS:
5723
+ return D.DATA_LOSS;
5724
5724
 
5725
5725
  default:
5726
5726
  return fail();
@@ -5734,14 +5734,14 @@ function __PRIVATE_mapCodeFromRpcCode(e) {
5734
5734
  * "UNKNOWN", etc.)
5735
5735
  * @returns The equivalent Code. Non-matching responses are mapped to
5736
5736
  * Code.UNKNOWN.
5737
- */ (ce = ue || (ue = {}))[ce.OK = 0] = "OK", ce[ce.CANCELLED = 1] = "CANCELLED",
5738
- ce[ce.UNKNOWN = 2] = "UNKNOWN", ce[ce.INVALID_ARGUMENT = 3] = "INVALID_ARGUMENT",
5739
- ce[ce.DEADLINE_EXCEEDED = 4] = "DEADLINE_EXCEEDED", ce[ce.NOT_FOUND = 5] = "NOT_FOUND",
5740
- ce[ce.ALREADY_EXISTS = 6] = "ALREADY_EXISTS", ce[ce.PERMISSION_DENIED = 7] = "PERMISSION_DENIED",
5741
- ce[ce.UNAUTHENTICATED = 16] = "UNAUTHENTICATED", ce[ce.RESOURCE_EXHAUSTED = 8] = "RESOURCE_EXHAUSTED",
5742
- ce[ce.FAILED_PRECONDITION = 9] = "FAILED_PRECONDITION", ce[ce.ABORTED = 10] = "ABORTED",
5743
- ce[ce.OUT_OF_RANGE = 11] = "OUT_OF_RANGE", ce[ce.UNIMPLEMENTED = 12] = "UNIMPLEMENTED",
5744
- ce[ce.INTERNAL = 13] = "INTERNAL", ce[ce.UNAVAILABLE = 14] = "UNAVAILABLE", ce[ce.DATA_LOSS = 15] = "DATA_LOSS";
5737
+ */ (ue = ae || (ae = {}))[ue.OK = 0] = "OK", ue[ue.CANCELLED = 1] = "CANCELLED",
5738
+ ue[ue.UNKNOWN = 2] = "UNKNOWN", ue[ue.INVALID_ARGUMENT = 3] = "INVALID_ARGUMENT",
5739
+ ue[ue.DEADLINE_EXCEEDED = 4] = "DEADLINE_EXCEEDED", ue[ue.NOT_FOUND = 5] = "NOT_FOUND",
5740
+ ue[ue.ALREADY_EXISTS = 6] = "ALREADY_EXISTS", ue[ue.PERMISSION_DENIED = 7] = "PERMISSION_DENIED",
5741
+ ue[ue.UNAUTHENTICATED = 16] = "UNAUTHENTICATED", ue[ue.RESOURCE_EXHAUSTED = 8] = "RESOURCE_EXHAUSTED",
5742
+ ue[ue.FAILED_PRECONDITION = 9] = "FAILED_PRECONDITION", ue[ue.ABORTED = 10] = "ABORTED",
5743
+ ue[ue.OUT_OF_RANGE = 11] = "OUT_OF_RANGE", ue[ue.UNIMPLEMENTED = 12] = "UNIMPLEMENTED",
5744
+ ue[ue.INTERNAL = 13] = "INTERNAL", ue[ue.UNAVAILABLE = 14] = "UNAVAILABLE", ue[ue.DATA_LOSS = 15] = "DATA_LOSS";
5745
5745
 
5746
5746
  /**
5747
5747
  * @license
@@ -5766,7 +5766,7 @@ ce[ce.INTERNAL = 13] = "INTERNAL", ce[ce.UNAVAILABLE = 14] = "UNAVAILABLE", ce[c
5766
5766
  * integration tests that have registered callbacks to be notified of events
5767
5767
  * that happen during the test execution.
5768
5768
  */
5769
- let le = null;
5769
+ let ce = null;
5770
5770
 
5771
5771
  /**
5772
5772
  * Sets the value of the `testingHooksSpi` object.
@@ -5814,7 +5814,7 @@ function __PRIVATE_newTextEncoder() {
5814
5814
  * See the License for the specific language governing permissions and
5815
5815
  * limitations under the License.
5816
5816
  */
5817
- const he = new webchannelWrapper.Integer([ 4294967295, 4294967295 ], 0);
5817
+ const le = new webchannelWrapper.Integer([ 4294967295, 4294967295 ], 0);
5818
5818
 
5819
5819
  // Hash a string using md5 hashing algorithm.
5820
5820
  function __PRIVATE_getMd5HashValue(e) {
@@ -5841,16 +5841,16 @@ class BloomFilter {
5841
5841
  throw new __PRIVATE_BloomFilterError(`Invalid padding when bitmap length is 0: ${t}`);
5842
5842
  this.Te = 8 * e.length - t,
5843
5843
  // Set the bit count in Integer to avoid repetition in mightContain().
5844
- this.de = webchannelWrapper.Integer.fromNumber(this.Te);
5844
+ this.Ee = webchannelWrapper.Integer.fromNumber(this.Te);
5845
5845
  }
5846
5846
  // Calculate the ith hash value based on the hashed 64bit integers,
5847
5847
  // and calculate its corresponding bit index in the bitmap to be checked.
5848
- Ee(e, t, n) {
5848
+ de(e, t, n) {
5849
5849
  // Calculate hashed value h(i) = h1 + (i * h2).
5850
5850
  let r = e.add(t.multiply(webchannelWrapper.Integer.fromNumber(n)));
5851
5851
  // Wrap if hash value overflow 64bit.
5852
- return 1 === r.compare(he) && (r = new webchannelWrapper.Integer([ r.getBits(0), r.getBits(1) ], 0)),
5853
- r.modulo(this.de).toNumber();
5852
+ return 1 === r.compare(le) && (r = new webchannelWrapper.Integer([ r.getBits(0), r.getBits(1) ], 0)),
5853
+ r.modulo(this.Ee).toNumber();
5854
5854
  }
5855
5855
  // Return whether the bit on the given index in the bitmap is set to 1.
5856
5856
  Ae(e) {
@@ -5861,7 +5861,7 @@ class BloomFilter {
5861
5861
  if (0 === this.Te) return !1;
5862
5862
  const t = __PRIVATE_getMd5HashValue(e), [n, r] = __PRIVATE_get64BitUints(t);
5863
5863
  for (let e = 0; e < this.hashCount; e++) {
5864
- const t = this.Ee(n, r, e);
5864
+ const t = this.de(n, r, e);
5865
5865
  if (!this.Ae(t)) return !1;
5866
5866
  }
5867
5867
  return !0;
@@ -5874,7 +5874,7 @@ class BloomFilter {
5874
5874
  if (0 === this.Te) return;
5875
5875
  const t = __PRIVATE_getMd5HashValue(e), [n, r] = __PRIVATE_get64BitUints(t);
5876
5876
  for (let e = 0; e < this.hashCount; e++) {
5877
- const t = this.Ee(n, r, e);
5877
+ const t = this.de(n, r, e);
5878
5878
  this.Re(t);
5879
5879
  }
5880
5880
  }
@@ -6152,7 +6152,7 @@ class __PRIVATE_WatchTargetChange {
6152
6152
  this.ge += 1;
6153
6153
  }
6154
6154
  Ne() {
6155
- this.ge -= 1;
6155
+ this.ge -= 1, __PRIVATE_hardAssert(this.ge >= 0);
6156
6156
  }
6157
6157
  Be() {
6158
6158
  this.Se = !0, this.we = !0;
@@ -6267,7 +6267,7 @@ class __PRIVATE_WatchChangeAggregator {
6267
6267
  const e = 2 /* BloomFilterApplicationStatus.FalsePositive */ === i ? "TargetPurposeExistenceFilterMismatchBloom" /* TargetPurpose.ExistenceFilterMismatchBloom */ : "TargetPurposeExistenceFilterMismatch" /* TargetPurpose.ExistenceFilterMismatch */;
6268
6268
  this.Ke = this.Ke.insert(t, e);
6269
6269
  }
6270
- null == le || le.tt(function __PRIVATE_createExistenceFilterMismatchInfoForTestingHooks(e, t, n, r, i) {
6270
+ null == ce || ce.tt(function __PRIVATE_createExistenceFilterMismatchInfoForTestingHooks(e, t, n, r, i) {
6271
6271
  var s, o, _, a, u, c;
6272
6272
  const l = {
6273
6273
  localCacheCount: e,
@@ -6483,13 +6483,13 @@ function __PRIVATE_snapshotChangesMap() {
6483
6483
  return new SortedMap(DocumentKey.comparator);
6484
6484
  }
6485
6485
 
6486
- const Pe = (() => {
6486
+ const he = (() => {
6487
6487
  const e = {
6488
6488
  asc: "ASCENDING",
6489
6489
  desc: "DESCENDING"
6490
6490
  };
6491
6491
  return e;
6492
- })(), Ie = (() => {
6492
+ })(), Pe = (() => {
6493
6493
  const e = {
6494
6494
  "<": "LESS_THAN",
6495
6495
  "<=": "LESS_THAN_OR_EQUAL",
@@ -6503,7 +6503,7 @@ const Pe = (() => {
6503
6503
  "array-contains-any": "ARRAY_CONTAINS_ANY"
6504
6504
  };
6505
6505
  return e;
6506
- })(), Te = (() => {
6506
+ })(), Ie = (() => {
6507
6507
  const e = {
6508
6508
  and: "AND",
6509
6509
  or: "OR"
@@ -6600,8 +6600,8 @@ function __PRIVATE_toName(e, t) {
6600
6600
 
6601
6601
  function fromName(e, t) {
6602
6602
  const n = __PRIVATE_fromResourceName(t);
6603
- if (n.get(1) !== e.databaseId.projectId) throw new FirestoreError(C.INVALID_ARGUMENT, "Tried to deserialize key from different project: " + n.get(1) + " vs " + e.databaseId.projectId);
6604
- if (n.get(3) !== e.databaseId.database) throw new FirestoreError(C.INVALID_ARGUMENT, "Tried to deserialize key from different database: " + n.get(3) + " vs " + e.databaseId.database);
6603
+ if (n.get(1) !== e.databaseId.projectId) throw new FirestoreError(D.INVALID_ARGUMENT, "Tried to deserialize key from different project: " + n.get(1) + " vs " + e.databaseId.projectId);
6604
+ if (n.get(3) !== e.databaseId.database) throw new FirestoreError(D.INVALID_ARGUMENT, "Tried to deserialize key from different database: " + n.get(3) + " vs " + e.databaseId.database);
6605
6605
  return new DocumentKey(__PRIVATE_extractLocalPathFromResourceName(n));
6606
6606
  }
6607
6607
 
@@ -6671,7 +6671,7 @@ function __PRIVATE_fromWatchChange(e, t) {
6671
6671
  ByteString.fromBase64String(t || "")) : (__PRIVATE_hardAssert(void 0 === t || t instanceof Uint8Array),
6672
6672
  ByteString.fromUint8Array(t || new Uint8Array));
6673
6673
  }(e, t.targetChange.resumeToken), o = t.targetChange.cause, _ = o && function __PRIVATE_fromRpcStatus(e) {
6674
- const t = void 0 === e.code ? C.UNKNOWN : __PRIVATE_mapCodeFromRpcCode(e.code);
6674
+ const t = void 0 === e.code ? D.UNKNOWN : __PRIVATE_mapCodeFromRpcCode(e.code);
6675
6675
  return new FirestoreError(t, e.message || "");
6676
6676
  }(o);
6677
6677
  n = new __PRIVATE_WatchTargetChange(r, i, s, _ || null);
@@ -7027,15 +7027,15 @@ function __PRIVATE_fromFilter(e) {
7027
7027
  }
7028
7028
 
7029
7029
  function __PRIVATE_toDirection(e) {
7030
- return Pe[e];
7030
+ return he[e];
7031
7031
  }
7032
7032
 
7033
7033
  function __PRIVATE_toOperatorName(e) {
7034
- return Ie[e];
7034
+ return Pe[e];
7035
7035
  }
7036
7036
 
7037
7037
  function __PRIVATE_toCompositeOperatorName(e) {
7038
- return Te[e];
7038
+ return Ie[e];
7039
7039
  }
7040
7040
 
7041
7041
  function __PRIVATE_toFieldPathReference(e) {
@@ -7587,18 +7587,18 @@ class __PRIVATE_FirestoreIndexValueWriter {
7587
7587
  }
7588
7588
  Pt(e, t) {
7589
7589
  if ("nullValue" in e) this.Tt(t, 5); else if ("booleanValue" in e) this.Tt(t, 10),
7590
- t.dt(e.booleanValue ? 1 : 0); else if ("integerValue" in e) this.Tt(t, 15), t.dt(__PRIVATE_normalizeNumber(e.integerValue)); else if ("doubleValue" in e) {
7590
+ t.Et(e.booleanValue ? 1 : 0); else if ("integerValue" in e) this.Tt(t, 15), t.Et(__PRIVATE_normalizeNumber(e.integerValue)); else if ("doubleValue" in e) {
7591
7591
  const n = __PRIVATE_normalizeNumber(e.doubleValue);
7592
7592
  isNaN(n) ? this.Tt(t, 13) : (this.Tt(t, 15), __PRIVATE_isNegativeZero(n) ?
7593
7593
  // -0.0, 0 and 0.0 are all considered the same
7594
- t.dt(0) : t.dt(n));
7594
+ t.Et(0) : t.Et(n));
7595
7595
  } else if ("timestampValue" in e) {
7596
7596
  const n = e.timestampValue;
7597
- this.Tt(t, 20), "string" == typeof n ? t.Et(n) : (t.Et(`${n.seconds || ""}`), t.dt(n.nanos || 0));
7597
+ this.Tt(t, 20), "string" == typeof n ? t.dt(n) : (t.dt(`${n.seconds || ""}`), t.Et(n.nanos || 0));
7598
7598
  } else if ("stringValue" in e) this.At(e.stringValue, t), this.Rt(t); else if ("bytesValue" in e) this.Tt(t, 30),
7599
7599
  t.Vt(__PRIVATE_normalizeByteString(e.bytesValue)), this.Rt(t); else if ("referenceValue" in e) this.ft(e.referenceValue, t); else if ("geoPointValue" in e) {
7600
7600
  const n = e.geoPointValue;
7601
- this.Tt(t, 45), t.dt(n.latitude || 0), t.dt(n.longitude || 0);
7601
+ this.Tt(t, 45), t.Et(n.latitude || 0), t.Et(n.longitude || 0);
7602
7602
  } else "mapValue" in e ? __PRIVATE_isMaxValue(e) ? this.Tt(t, Number.MAX_SAFE_INTEGER) : (this.gt(e.mapValue, t),
7603
7603
  this.Rt(t)) : "arrayValue" in e ? (this.yt(e.arrayValue, t), this.Rt(t)) : fail();
7604
7604
  }
@@ -7606,7 +7606,7 @@ class __PRIVATE_FirestoreIndexValueWriter {
7606
7606
  this.Tt(t, 25), this.wt(e, t);
7607
7607
  }
7608
7608
  wt(e, t) {
7609
- t.Et(e);
7609
+ t.dt(e);
7610
7610
  }
7611
7611
  gt(e, t) {
7612
7612
  const n = e.fields || {};
@@ -7625,13 +7625,13 @@ class __PRIVATE_FirestoreIndexValueWriter {
7625
7625
  }));
7626
7626
  }
7627
7627
  Tt(e, t) {
7628
- e.dt(t);
7628
+ e.Et(t);
7629
7629
  }
7630
7630
  Rt(e) {
7631
7631
  // While the SDK does not implement truncation, the truncation marker is
7632
7632
  // used to terminate all variable length values (which are strings, bytes,
7633
7633
  // references, arrays and maps).
7634
- e.dt(2);
7634
+ e.Et(2);
7635
7635
  }
7636
7636
  }
7637
7637
 
@@ -7818,10 +7818,10 @@ class __PRIVATE_AscendingIndexByteEncoder {
7818
7818
  Vt(e) {
7819
7819
  this.Wt.bt(e);
7820
7820
  }
7821
- Et(e) {
7821
+ dt(e) {
7822
7822
  this.Wt.xt(e);
7823
7823
  }
7824
- dt(e) {
7824
+ Et(e) {
7825
7825
  this.Wt.Nt(e);
7826
7826
  }
7827
7827
  It() {
@@ -7836,10 +7836,10 @@ class __PRIVATE_DescendingIndexByteEncoder {
7836
7836
  Vt(e) {
7837
7837
  this.Wt.vt(e);
7838
7838
  }
7839
- Et(e) {
7839
+ dt(e) {
7840
7840
  this.Wt.Ot(e);
7841
7841
  }
7842
- dt(e) {
7842
+ Et(e) {
7843
7843
  this.Wt.kt(e);
7844
7844
  }
7845
7845
  It() {
@@ -8356,7 +8356,7 @@ function __PRIVATE_applyDistributionFieldAndCompositeFilters(e, t) {
8356
8356
  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
8357
8357
  * See the License for the specific language governing permissions and
8358
8358
  * limitations under the License.
8359
- */ const de = new Uint8Array(0);
8359
+ */ const Te = new Uint8Array(0);
8360
8360
 
8361
8361
  /**
8362
8362
  * A persisted implementation of IndexManager.
@@ -8570,7 +8570,7 @@ class __PRIVATE_IndexedDbIndexManager {
8570
8570
  // combined with the values from the query bounds.
8571
8571
  const _ = (null != t ? t.length : 1) * Math.max(n.length, i.length), a = _ / (null != t ? t.length : 1), u = [];
8572
8572
  for (let c = 0; c < _; ++c) {
8573
- const _ = t ? this.In(t[c / a]) : de, l = this.Tn(e, _, n[c % a], r), h = this.dn(e, _, i[c % a], s), P = o.map((t => this.Tn(e, _, t,
8573
+ const _ = t ? this.In(t[c / a]) : Te, l = this.Tn(e, _, n[c % a], r), h = this.En(e, _, i[c % a], s), P = o.map((t => this.Tn(e, _, t,
8574
8574
  /* inclusive= */ !0)));
8575
8575
  u.push(...this.createRange(l, h, P));
8576
8576
  }
@@ -8580,7 +8580,7 @@ class __PRIVATE_IndexedDbIndexManager {
8580
8580
  const i = new __PRIVATE_IndexEntry(e, DocumentKey.empty(), t, n);
8581
8581
  return r ? i : i.Ht();
8582
8582
  }
8583
- /** Generates the upper bound for `arrayValue` and `directionalValue`. */ dn(e, t, n, r) {
8583
+ /** Generates the upper bound for `arrayValue` and `directionalValue`. */ En(e, t, n, r) {
8584
8584
  const i = new __PRIVATE_IndexEntry(e, DocumentKey.empty(), t, n);
8585
8585
  return r ? i.Ht() : i;
8586
8586
  }
@@ -8628,7 +8628,7 @@ class __PRIVATE_IndexedDbIndexManager {
8628
8628
  * Returns the byte encoded form of the directional values in the field index.
8629
8629
  * Returns `null` if the document does not have all fields specified in the
8630
8630
  * index.
8631
- */ En(e, t) {
8631
+ */ dn(e, t) {
8632
8632
  const n = new __PRIVATE_IndexByteEncoder;
8633
8633
  for (const r of __PRIVATE_fieldIndexGetDirectionalSegments(e)) {
8634
8634
  const e = t.data.field(r.fieldPath);
@@ -8761,13 +8761,13 @@ class __PRIVATE_IndexedDbIndexManager {
8761
8761
  }
8762
8762
  /** Creates the index entries for the given document. */ pn(e, t) {
8763
8763
  let n = new SortedSet(__PRIVATE_indexEntryComparator);
8764
- const r = this.En(t, e);
8764
+ const r = this.dn(t, e);
8765
8765
  if (null == r) return n;
8766
8766
  const i = __PRIVATE_fieldIndexGetArraySegment(t);
8767
8767
  if (null != i) {
8768
8768
  const s = e.data.field(i.fieldPath);
8769
8769
  if (isArray(s)) for (const i of s.arrayValue.values || []) n = n.add(new __PRIVATE_IndexEntry(t.indexId, e.key, this.In(i), r));
8770
- } else n = n.add(new __PRIVATE_IndexEntry(t.indexId, e.key, de, r));
8770
+ } else n = n.add(new __PRIVATE_IndexEntry(t.indexId, e.key, Te, r));
8771
8771
  return n;
8772
8772
  }
8773
8773
  /**
@@ -8842,7 +8842,7 @@ class __PRIVATE_IndexedDbIndexManager {
8842
8842
  // If we encounter two bounds that will create an unmatchable key range,
8843
8843
  // then we return an empty set of key ranges.
8844
8844
  if (this.bn(r[e], r[e + 1])) return [];
8845
- const t = [ r[e].indexId, this.uid, r[e].arrayValue, r[e].directionalValue, de, [] ], n = [ r[e + 1].indexId, this.uid, r[e + 1].arrayValue, r[e + 1].directionalValue, de, [] ];
8845
+ const t = [ r[e].indexId, this.uid, r[e].arrayValue, r[e].directionalValue, Te, [] ], n = [ r[e + 1].indexId, this.uid, r[e + 1].arrayValue, r[e + 1].directionalValue, Te, [] ];
8846
8846
  i.push(IDBKeyRange.bound(t, n));
8847
8847
  }
8848
8848
  return i;
@@ -9074,7 +9074,7 @@ class __PRIVATE_IndexedDbMutationQueue {
9074
9074
  let c = new SortedSet(((e, t) => __PRIVATE_primitiveComparator(e.canonicalString(), t.canonicalString())));
9075
9075
  for (const e of r) {
9076
9076
  const t = __PRIVATE_newDbDocumentMutationKey(this.userId, e.key.path, o);
9077
- c = c.add(e.key.path.popLast()), u.push(s.put(a)), u.push(i.put(t, O));
9077
+ c = c.add(e.key.path.popLast()), u.push(s.put(a)), u.push(i.put(t, x));
9078
9078
  }
9079
9079
  return c.forEach((t => {
9080
9080
  u.push(this.indexManager.addToCollectionParentIndex(e, t));
@@ -10695,14 +10695,14 @@ class OverlayedDocument {
10695
10695
  const n = new __PRIVATE_DocReference(e, t);
10696
10696
  this.hr = this.hr.add(n), this.Ir = this.Ir.add(n);
10697
10697
  }
10698
- /** Add references to the given document keys for the given ID. */ dr(e, t) {
10698
+ /** Add references to the given document keys for the given ID. */ Er(e, t) {
10699
10699
  e.forEach((e => this.addReference(e, t)));
10700
10700
  }
10701
10701
  /**
10702
10702
  * Removes a reference to the given document key for the given
10703
10703
  * ID.
10704
10704
  */ removeReference(e, t) {
10705
- this.Er(new __PRIVATE_DocReference(e, t));
10705
+ this.dr(new __PRIVATE_DocReference(e, t));
10706
10706
  }
10707
10707
  Ar(e, t) {
10708
10708
  e.forEach((e => this.removeReference(e, t)));
@@ -10713,13 +10713,13 @@ class OverlayedDocument {
10713
10713
  */ Rr(e) {
10714
10714
  const t = new DocumentKey(new ResourcePath([])), n = new __PRIVATE_DocReference(t, e), r = new __PRIVATE_DocReference(t, e + 1), i = [];
10715
10715
  return this.Ir.forEachInRange([ n, r ], (e => {
10716
- this.Er(e), i.push(e.key);
10716
+ this.dr(e), i.push(e.key);
10717
10717
  })), i;
10718
10718
  }
10719
10719
  Vr() {
10720
- this.hr.forEach((e => this.Er(e)));
10720
+ this.hr.forEach((e => this.dr(e)));
10721
10721
  }
10722
- Er(e) {
10722
+ dr(e) {
10723
10723
  this.hr = this.hr.delete(e), this.Ir = this.Ir.delete(e);
10724
10724
  }
10725
10725
  mr(e) {
@@ -11121,7 +11121,7 @@ class __PRIVATE_MemoryRemoteDocumentChangeBuffer extends RemoteDocumentChangeBuf
11121
11121
  return PersistencePromise.resolve(n);
11122
11122
  }
11123
11123
  addMatchingKeys(e, t, n) {
11124
- return this.Or.dr(t, n), PersistencePromise.resolve();
11124
+ return this.Or.Er(t, n), PersistencePromise.resolve();
11125
11125
  }
11126
11126
  removeMatchingKeys(e, t, n) {
11127
11127
  this.Or.Ar(t, n);
@@ -11403,7 +11403,7 @@ class __PRIVATE_MemoryLruDelegate {
11403
11403
  e.createObjectStore("mutations", {
11404
11404
  keyPath: "batchId",
11405
11405
  autoIncrement: !0
11406
- }).createIndex("userMutationsIndex", x, {
11406
+ }).createIndex("userMutationsIndex", M, {
11407
11407
  unique: !0
11408
11408
  }), e.createObjectStore("documentMutations");
11409
11409
  }
@@ -11448,7 +11448,7 @@ class __PRIVATE_MemoryLruDelegate {
11448
11448
  e.createObjectStore("mutations", {
11449
11449
  keyPath: "batchId",
11450
11450
  autoIncrement: !0
11451
- }).createIndex("userMutationsIndex", x, {
11451
+ }).createIndex("userMutationsIndex", M, {
11452
11452
  unique: !0
11453
11453
  });
11454
11454
  const r = t.store("mutations"), i = n.map((e => r.put(e)));
@@ -11485,19 +11485,19 @@ class __PRIVATE_MemoryLruDelegate {
11485
11485
  }))), n < 12 && r >= 12 && (s = s.next((() => {
11486
11486
  !function __PRIVATE_createDocumentOverlayStore(e) {
11487
11487
  const t = e.createObjectStore("documentOverlays", {
11488
- keyPath: z
11488
+ keyPath: G
11489
11489
  });
11490
- t.createIndex("collectionPathOverlayIndex", j, {
11490
+ t.createIndex("collectionPathOverlayIndex", z, {
11491
11491
  unique: !1
11492
- }), t.createIndex("collectionGroupOverlayIndex", H, {
11492
+ }), t.createIndex("collectionGroupOverlayIndex", j, {
11493
11493
  unique: !1
11494
11494
  });
11495
11495
  }(e);
11496
11496
  }))), n < 13 && r >= 13 && (s = s.next((() => function __PRIVATE_createRemoteDocumentCache(e) {
11497
11497
  const t = e.createObjectStore("remoteDocumentsV14", {
11498
- keyPath: N
11498
+ keyPath: O
11499
11499
  });
11500
- t.createIndex("documentKeyIndex", B), t.createIndex("collectionGroupIndex", L);
11500
+ t.createIndex("documentKeyIndex", N), t.createIndex("collectionGroupIndex", B);
11501
11501
  }(e))).next((() => this.ri(e, i))).next((() => e.deleteObjectStore("remoteDocuments")))),
11502
11502
  n < 14 && r >= 14 && (s = s.next((() => this.ii(e, i)))), n < 15 && r >= 15 && (s = s.next((() => function __PRIVATE_createFieldIndex(e) {
11503
11503
  e.createObjectStore("indexConfiguration", {
@@ -11507,13 +11507,13 @@ class __PRIVATE_MemoryLruDelegate {
11507
11507
  unique: !1
11508
11508
  });
11509
11509
  e.createObjectStore("indexState", {
11510
- keyPath: $
11511
- }).createIndex("sequenceNumberIndex", U, {
11510
+ keyPath: K
11511
+ }).createIndex("sequenceNumberIndex", $, {
11512
11512
  unique: !1
11513
11513
  });
11514
11514
  e.createObjectStore("indexEntries", {
11515
- keyPath: W
11516
- }).createIndex("documentKeyIndex", G, {
11515
+ keyPath: U
11516
+ }).createIndex("documentKeyIndex", W, {
11517
11517
  unique: !1
11518
11518
  });
11519
11519
  }(e)))), s;
@@ -11562,7 +11562,7 @@ class __PRIVATE_MemoryLruDelegate {
11562
11562
  ti(e, t) {
11563
11563
  // Create the index.
11564
11564
  e.createObjectStore("collectionParents", {
11565
- keyPath: K
11565
+ keyPath: Q
11566
11566
  });
11567
11567
  const n = t.store("collectionParents"), r = new __PRIVATE_MemoryCollectionParentIndex, addEntry = e => {
11568
11568
  if (r.add(e)) {
@@ -11647,19 +11647,19 @@ class __PRIVATE_MemoryLruDelegate {
11647
11647
 
11648
11648
  function __PRIVATE_createQueryCache(e) {
11649
11649
  e.createObjectStore("targetDocuments", {
11650
- keyPath: q
11651
- }).createIndex("documentTargetsIndex", Q, {
11650
+ keyPath: k
11651
+ }).createIndex("documentTargetsIndex", q, {
11652
11652
  unique: !0
11653
11653
  });
11654
11654
  // NOTE: This is unique only because the TargetId is the suffix.
11655
11655
  e.createObjectStore("targets", {
11656
11656
  keyPath: "targetId"
11657
- }).createIndex("queryTargetsIndex", k, {
11657
+ }).createIndex("queryTargetsIndex", L, {
11658
11658
  unique: !0
11659
11659
  }), e.createObjectStore("targetGlobal");
11660
11660
  }
11661
11661
 
11662
- const Ae = "Failed to obtain exclusive access to the persistence layer. To allow shared access, multi-tab synchronization has to be enabled in all tabs. If you are using `experimentalForceOwningTab:true`, make sure that only one tab has persistence enabled at any given time.";
11662
+ const de = "Failed to obtain exclusive access to the persistence layer. To allow shared access, multi-tab synchronization has to be enabled in all tabs. If you are using `experimentalForceOwningTab:true`, make sure that only one tab has persistence enabled at any given time.";
11663
11663
 
11664
11664
  /**
11665
11665
  * Oldest acceptable age in milliseconds for client metadata before the client
@@ -11735,12 +11735,12 @@ class __PRIVATE_IndexedDbPersistence {
11735
11735
  /** The last time we garbage collected the client metadata object store. */
11736
11736
  this.hi = Number.NEGATIVE_INFINITY,
11737
11737
  /** A listener to notify on primary state changes. */
11738
- this.Pi = e => Promise.resolve(), !__PRIVATE_IndexedDbPersistence.D()) throw new FirestoreError(C.UNIMPLEMENTED, "This platform is either missing IndexedDB or is known to have an incomplete implementation. Offline persistence has been disabled.");
11738
+ this.Pi = e => Promise.resolve(), !__PRIVATE_IndexedDbPersistence.D()) throw new FirestoreError(D.UNIMPLEMENTED, "This platform is either missing IndexedDB or is known to have an incomplete implementation. Offline persistence has been disabled.");
11739
11739
  this.referenceDelegate = new __PRIVATE_IndexedDbLruDelegateImpl(this, r), this.Ii = t + "main",
11740
11740
  this.serializer = new __PRIVATE_LocalSerializer(_), this.Ti = new __PRIVATE_SimpleDb(this.Ii, this.ai, new __PRIVATE_SchemaConverter(this.serializer)),
11741
11741
  this.qr = new __PRIVATE_IndexedDbTargetCache(this.referenceDelegate, this.serializer),
11742
11742
  this.remoteDocumentCache = __PRIVATE_newIndexedDbRemoteDocumentCache(this.serializer),
11743
- this.Kr = new __PRIVATE_IndexedDbBundleCache, this.window && this.window.localStorage ? this.di = this.window.localStorage : (this.di = null,
11743
+ this.Kr = new __PRIVATE_IndexedDbBundleCache, this.window && this.window.localStorage ? this.Ei = this.window.localStorage : (this.Ei = null,
11744
11744
  !1 === u && __PRIVATE_logError("IndexedDbPersistence", "LocalStorage is unavailable. As a result, persistence may not work reliably. In particular enablePersistence() could fail immediately after refreshing the page."));
11745
11745
  }
11746
11746
  /**
@@ -11751,11 +11751,11 @@ class __PRIVATE_IndexedDbPersistence {
11751
11751
  // NOTE: This is expected to fail sometimes (in the case of another tab
11752
11752
  // already having the persistence lock), so it's the first thing we should
11753
11753
  // do.
11754
- return this.Ei().then((() => {
11754
+ return this.di().then((() => {
11755
11755
  if (!this.isPrimary && !this.allowTabSynchronization)
11756
11756
  // Fail `start()` if `synchronizeTabs` is disabled and we cannot
11757
11757
  // obtain the primary lease.
11758
- throw new FirestoreError(C.FAILED_PRECONDITION, Ae);
11758
+ throw new FirestoreError(D.FAILED_PRECONDITION, de);
11759
11759
  return this.Ai(), this.Ri(), this.Vi(), this.runTransaction("getHighestListenSequenceNumber", "readonly", (e => this.qr.getHighestSequenceNumber(e)));
11760
11760
  })).then((e => {
11761
11761
  this.Lr = new __PRIVATE_ListenSequence(e, this.oi);
@@ -11795,7 +11795,7 @@ class __PRIVATE_IndexedDbPersistence {
11795
11795
  // Schedule a primary lease refresh for immediate execution. The eventual
11796
11796
  // lease update will be propagated via `primaryStateListener`.
11797
11797
  this.si.enqueueAndForget((async () => {
11798
- this.started && await this.Ei();
11798
+ this.started && await this.di();
11799
11799
  })));
11800
11800
  }
11801
11801
  /**
@@ -11803,7 +11803,7 @@ class __PRIVATE_IndexedDbPersistence {
11803
11803
  * extend the primary lease for the local client. Asynchronously notifies the
11804
11804
  * primary state listener if the client either newly obtained or released its
11805
11805
  * primary lease.
11806
- */ Ei() {
11806
+ */ di() {
11807
11807
  return this.runTransaction("updateClientMetadataAndTryBecomePrimary", "readwrite", (e => __PRIVATE_clientMetadataStore(e).put({
11808
11808
  clientId: this.clientId,
11809
11809
  updateTimeMs: Date.now(),
@@ -11852,14 +11852,14 @@ class __PRIVATE_IndexedDbPersistence {
11852
11852
  // Ideally we'd delete the IndexedDb and LocalStorage zombie entries for
11853
11853
  // the client atomically, but we can't. So we opt to delete the IndexedDb
11854
11854
  // entries first to avoid potentially reviving a zombied client.
11855
- if (this.di) for (const t of e) this.di.removeItem(this.vi(t.clientId));
11855
+ if (this.Ei) for (const t of e) this.Ei.removeItem(this.vi(t.clientId));
11856
11856
  }
11857
11857
  }
11858
11858
  /**
11859
11859
  * Schedules a recurring timer to update the client metadata and to either
11860
11860
  * extend or acquire the primary lease if the client is eligible.
11861
11861
  */ Vi() {
11862
- this.li = this.si.enqueueAfterDelay("client_metadata_refresh" /* TimerId.ClientMetadataRefresh */ , 4e3, (() => this.Ei().then((() => this.bi())).then((() => this.Vi()))));
11862
+ this.li = this.si.enqueueAfterDelay("client_metadata_refresh" /* TimerId.ClientMetadataRefresh */ , 4e3, (() => this.di().then((() => this.bi())).then((() => this.Vi()))));
11863
11863
  }
11864
11864
  /** Checks whether `client` is the local client. */ wi(e) {
11865
11865
  return !!e && e.ownerId === this.clientId;
@@ -11897,7 +11897,7 @@ class __PRIVATE_IndexedDbPersistence {
11897
11897
  // settings is not supported.
11898
11898
  // TODO(b/114226234): Remove this check when `synchronizeTabs` can
11899
11899
  // no longer be turned off.
11900
- throw new FirestoreError(C.FAILED_PRECONDITION, Ae);
11900
+ throw new FirestoreError(D.FAILED_PRECONDITION, de);
11901
11901
  return !1;
11902
11902
  }
11903
11903
  }
@@ -11967,7 +11967,7 @@ class __PRIVATE_IndexedDbPersistence {
11967
11967
  const r = "readonly" === t ? "readonly" : "readwrite", i =
11968
11968
  /** Returns the object stores for the provided schema. */
11969
11969
  function __PRIVATE_getObjectStores(e) {
11970
- return 15 === e ? ee : 14 === e ? X : 13 === e ? Z : 12 === e ? Y : 11 === e ? J : void fail();
11970
+ return 15 === e ? X : 14 === e ? Z : 13 === e ? Y : 12 === e ? J : 11 === e ? H : void fail();
11971
11971
  }(this.ai);
11972
11972
  let s;
11973
11973
  // Do all transactions as readwrite against all object stores, since we
@@ -11975,7 +11975,7 @@ class __PRIVATE_IndexedDbPersistence {
11975
11975
  return this.Ti.runTransaction(e, r, i, (r => (s = new __PRIVATE_IndexedDbTransaction(r, this.Lr ? this.Lr.next() : __PRIVATE_ListenSequence._e),
11976
11976
  "readwrite-primary" === t ? this.fi(s).next((e => !!e || this.gi(s))).next((t => {
11977
11977
  if (!t) throw __PRIVATE_logError(`Failed to obtain primary lease for action '${e}'.`),
11978
- this.isPrimary = !1, this.si.enqueueRetryable((() => this.Pi(!1))), new FirestoreError(C.FAILED_PRECONDITION, F);
11978
+ this.isPrimary = !1, this.si.enqueueRetryable((() => this.Pi(!1))), new FirestoreError(D.FAILED_PRECONDITION, v);
11979
11979
  return n(s);
11980
11980
  })).next((e => this.yi(s).next((() => e)))) : this.Li(s).next((() => n(s)))))).then((e => (s.raiseOnCommittedEvent(),
11981
11981
  e)));
@@ -11988,7 +11988,7 @@ class __PRIVATE_IndexedDbPersistence {
11988
11988
  // be turned off.
11989
11989
  Li(e) {
11990
11990
  return __PRIVATE_primaryClientStore(e).get("owner").next((e => {
11991
- if (null !== e && this.Di(e.leaseTimestampMs, 5e3) && !this.Fi(e.ownerId) && !this.wi(e) && !(this._i || this.allowTabSynchronization && e.allowTabSynchronization)) throw new FirestoreError(C.FAILED_PRECONDITION, Ae);
11991
+ if (null !== e && this.Di(e.leaseTimestampMs, 5e3) && !this.Fi(e.ownerId) && !this.wi(e) && !(this._i || this.allowTabSynchronization && e.allowTabSynchronization)) throw new FirestoreError(D.FAILED_PRECONDITION, de);
11992
11992
  }));
11993
11993
  }
11994
11994
  /**
@@ -12018,7 +12018,7 @@ class __PRIVATE_IndexedDbPersistence {
12018
12018
  Ai() {
12019
12019
  null !== this.document && "function" == typeof this.document.addEventListener && (this.ci = () => {
12020
12020
  this.si.enqueueAndForget((() => (this.inForeground = "visible" === this.document.visibilityState,
12021
- this.Ei())));
12021
+ this.di())));
12022
12022
  }, this.document.addEventListener("visibilitychange", this.ci), this.inForeground = "visible" === this.document.visibilityState);
12023
12023
  }
12024
12024
  xi() {
@@ -12059,7 +12059,7 @@ class __PRIVATE_IndexedDbPersistence {
12059
12059
  */ Fi(e) {
12060
12060
  var t;
12061
12061
  try {
12062
- const n = null !== (null === (t = this.di) || void 0 === t ? void 0 : t.getItem(this.vi(e)));
12062
+ const n = null !== (null === (t = this.Ei) || void 0 === t ? void 0 : t.getItem(this.vi(e)));
12063
12063
  return __PRIVATE_logDebug("IndexedDbPersistence", `Client '${e}' ${n ? "is" : "is not"} zombied in LocalStorage`),
12064
12064
  n;
12065
12065
  } catch (e) {
@@ -12072,16 +12072,16 @@ class __PRIVATE_IndexedDbPersistence {
12072
12072
  * Record client as zombied (a client that had its tab closed). Zombied
12073
12073
  * clients are ignored during primary tab selection.
12074
12074
  */ Mi() {
12075
- if (this.di) try {
12076
- this.di.setItem(this.vi(this.clientId), String(Date.now()));
12075
+ if (this.Ei) try {
12076
+ this.Ei.setItem(this.vi(this.clientId), String(Date.now()));
12077
12077
  } catch (e) {
12078
12078
  // Gracefully handle if LocalStorage isn't available / working.
12079
12079
  __PRIVATE_logError("Failed to set zombie client id.", e);
12080
12080
  }
12081
12081
  }
12082
12082
  /** Removes the zombied client entry if it exists. */ Ni() {
12083
- if (this.di) try {
12084
- this.di.removeItem(this.vi(this.clientId));
12083
+ if (this.Ei) try {
12084
+ this.Ei.removeItem(this.vi(this.clientId));
12085
12085
  } catch (e) {
12086
12086
  // Ignore
12087
12087
  }
@@ -12895,7 +12895,7 @@ class __PRIVATE_MutationMetadata {
12895
12895
  s && (i = new FirestoreError(r.error.code, r.error.message))), s ? new __PRIVATE_MutationMetadata(e, t, r.state, i) : (__PRIVATE_logError("SharedClientState", `Failed to parse mutation state for ID '${t}': ${n}`),
12896
12896
  null);
12897
12897
  }
12898
- ds() {
12898
+ Es() {
12899
12899
  const e = {
12900
12900
  state: this.state,
12901
12901
  updateTimeMs: Date.now()
@@ -12926,7 +12926,7 @@ class __PRIVATE_QueryTargetMetadata {
12926
12926
  i && (r = new FirestoreError(n.error.code, n.error.message))), i ? new __PRIVATE_QueryTargetMetadata(e, n.state, r) : (__PRIVATE_logError("SharedClientState", `Failed to parse target state for ID '${e}': ${t}`),
12927
12927
  null);
12928
12928
  }
12929
- ds() {
12929
+ Es() {
12930
12930
  const e = {
12931
12931
  state: this.state,
12932
12932
  updateTimeMs: Date.now()
@@ -12991,7 +12991,7 @@ class __PRIVATE_LocalClientState {
12991
12991
  constructor() {
12992
12992
  this.activeTargetIds = __PRIVATE_targetIdSet();
12993
12993
  }
12994
- Es(e) {
12994
+ ds(e) {
12995
12995
  this.activeTargetIds = this.activeTargetIds.add(e);
12996
12996
  }
12997
12997
  As(e) {
@@ -13000,7 +13000,7 @@ class __PRIVATE_LocalClientState {
13000
13000
  /**
13001
13001
  * Converts this entry into a JSON-encoded format we can use for WebStorage.
13002
13002
  * Does not encode `clientId` as it is part of the key in WebStorage.
13003
- */ ds() {
13003
+ */ Es() {
13004
13004
  const e = {
13005
13005
  activeTargetIds: this.activeTargetIds.toArray(),
13006
13006
  updateTimeMs: Date.now()
@@ -13135,7 +13135,7 @@ class __PRIVATE_LocalClientState {
13135
13135
  r && (t = r.state);
13136
13136
  }
13137
13137
  }
13138
- return this.Ls.Es(e), this.Fs(), t;
13138
+ return this.Ls.ds(e), this.Fs(), t;
13139
13139
  }
13140
13140
  removeLocalQueryTarget(e) {
13141
13141
  this.Ls.As(e), this.Fs();
@@ -13237,11 +13237,11 @@ class __PRIVATE_LocalClientState {
13237
13237
  return this.gs.get(this.Rs);
13238
13238
  }
13239
13239
  Fs() {
13240
- this.setItem(this.ys, this.Ls.ds());
13240
+ this.setItem(this.ys, this.Ls.Es());
13241
13241
  }
13242
13242
  Ns(e, t, n) {
13243
13243
  const r = new __PRIVATE_MutationMetadata(this.currentUser, e, t, n), i = createWebStorageMutationBatchKey(this.persistenceKey, this.currentUser, e);
13244
- this.setItem(i, r.ds());
13244
+ this.setItem(i, r.Es());
13245
13245
  }
13246
13246
  Bs(e) {
13247
13247
  const t = createWebStorageMutationBatchKey(this.persistenceKey, this.currentUser, e);
@@ -13256,7 +13256,7 @@ class __PRIVATE_LocalClientState {
13256
13256
  }
13257
13257
  ks(e, t, n) {
13258
13258
  const r = createWebStorageQueryTargetMetadataKey(this.persistenceKey, e), i = new __PRIVATE_QueryTargetMetadata(e, t, n);
13259
- this.setItem(r, i.ds());
13259
+ this.setItem(r, i.Es());
13260
13260
  }
13261
13261
  Qs(e) {
13262
13262
  const t = JSON.stringify(Array.from(e));
@@ -13344,7 +13344,7 @@ class __PRIVATE_MemorySharedClientState {
13344
13344
  // No op.
13345
13345
  }
13346
13346
  addLocalQueryTarget(e) {
13347
- return this.eo.Es(e), this.no[e] || "not-current";
13347
+ return this.eo.ds(e), this.no[e] || "not-current";
13348
13348
  }
13349
13349
  updateQueryState(e, t, n) {
13350
13350
  this.no[e] = t;
@@ -13473,7 +13473,7 @@ class __PRIVATE_BrowserConnectivityMonitor {
13473
13473
  /**
13474
13474
  * The value returned from the most recent invocation of
13475
13475
  * `generateUniqueDebugId()`, or null if it has never been invoked.
13476
- */ let Re = null;
13476
+ */ let Ae = null;
13477
13477
 
13478
13478
  /**
13479
13479
  * Generates and returns an initial value for `lastUniqueDebugId`.
@@ -13498,9 +13498,9 @@ class __PRIVATE_BrowserConnectivityMonitor {
13498
13498
  * @return the 10-character generated ID (e.g. "0xa1b2c3d4").
13499
13499
  */
13500
13500
  function __PRIVATE_generateUniqueDebugId() {
13501
- return null === Re ? Re = function __PRIVATE_generateInitialUniqueDebugId() {
13501
+ return null === Ae ? Ae = function __PRIVATE_generateInitialUniqueDebugId() {
13502
13502
  return 268435456 + Math.round(2147483648 * Math.random());
13503
- }() : Re++, "0x" + Re.toString(16);
13503
+ }() : Ae++, "0x" + Ae.toString(16);
13504
13504
  }
13505
13505
 
13506
13506
  /**
@@ -13518,7 +13518,7 @@ function __PRIVATE_generateUniqueDebugId() {
13518
13518
  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13519
13519
  * See the License for the specific language governing permissions and
13520
13520
  * limitations under the License.
13521
- */ const Ve = {
13521
+ */ const Re = {
13522
13522
  BatchGetDocuments: "batchGet",
13523
13523
  Commit: "commit",
13524
13524
  RunQuery: "runQuery",
@@ -13596,7 +13596,7 @@ class __PRIVATE_StreamBridge {
13596
13596
  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13597
13597
  * See the License for the specific language governing permissions and
13598
13598
  * limitations under the License.
13599
- */ const me = "WebChannelConnection";
13599
+ */ const Ve = "WebChannelConnection";
13600
13600
 
13601
13601
  class __PRIVATE_WebChannelConnection extends
13602
13602
  /**
@@ -13640,7 +13640,7 @@ class __PRIVATE_RestConnection {
13640
13640
  // SDK_VERSION is updated to different value at runtime depending on the entry point,
13641
13641
  // so we need to get its value when we need it in a function.
13642
13642
  function __PRIVATE_getGoogApiClientValue() {
13643
- return "gl-js/ fire/" + b;
13643
+ return "gl-js/ fire/" + S;
13644
13644
  }(),
13645
13645
  // Content-Type: text/plain will avoid preflight requests which might
13646
13646
  // mess with CORS and redirects by proxies. If we add custom headers
@@ -13650,7 +13650,7 @@ class __PRIVATE_RestConnection {
13650
13650
  t && t.headers.forEach(((t, n) => e[n] = t)), n && n.headers.forEach(((t, n) => e[n] = t));
13651
13651
  }
13652
13652
  So(e, t) {
13653
- const n = Ve[e];
13653
+ const n = Re[e];
13654
13654
  return `${this.mo}/v1/${t}:${n}`;
13655
13655
  }
13656
13656
  } {
@@ -13667,17 +13667,17 @@ class __PRIVATE_RestConnection {
13667
13667
  switch (_.getLastErrorCode()) {
13668
13668
  case webchannelWrapper.ErrorCode.NO_ERROR:
13669
13669
  const t = _.getResponseJson();
13670
- __PRIVATE_logDebug(me, `XHR for RPC '${e}' ${i} received:`, JSON.stringify(t)),
13670
+ __PRIVATE_logDebug(Ve, `XHR for RPC '${e}' ${i} received:`, JSON.stringify(t)),
13671
13671
  s(t);
13672
13672
  break;
13673
13673
 
13674
13674
  case webchannelWrapper.ErrorCode.TIMEOUT:
13675
- __PRIVATE_logDebug(me, `RPC '${e}' ${i} timed out`), o(new FirestoreError(C.DEADLINE_EXCEEDED, "Request time out"));
13675
+ __PRIVATE_logDebug(Ve, `RPC '${e}' ${i} timed out`), o(new FirestoreError(D.DEADLINE_EXCEEDED, "Request time out"));
13676
13676
  break;
13677
13677
 
13678
13678
  case webchannelWrapper.ErrorCode.HTTP_ERROR:
13679
13679
  const n = _.getStatus();
13680
- if (__PRIVATE_logDebug(me, `RPC '${e}' ${i} failed with status:`, n, "response text:", _.getResponseText()),
13680
+ if (__PRIVATE_logDebug(Ve, `RPC '${e}' ${i} failed with status:`, n, "response text:", _.getResponseText()),
13681
13681
  n > 0) {
13682
13682
  let e = _.getResponseJson();
13683
13683
  Array.isArray(e) && (e = e[0]);
@@ -13685,25 +13685,25 @@ class __PRIVATE_RestConnection {
13685
13685
  if (t && t.status && t.message) {
13686
13686
  const e = function __PRIVATE_mapCodeFromHttpResponseErrorStatus(e) {
13687
13687
  const t = e.toLowerCase().replace(/_/g, "-");
13688
- return Object.values(C).indexOf(t) >= 0 ? t : C.UNKNOWN;
13688
+ return Object.values(D).indexOf(t) >= 0 ? t : D.UNKNOWN;
13689
13689
  }(t.status);
13690
13690
  o(new FirestoreError(e, t.message));
13691
- } else o(new FirestoreError(C.UNKNOWN, "Server responded with status " + _.getStatus()));
13691
+ } else o(new FirestoreError(D.UNKNOWN, "Server responded with status " + _.getStatus()));
13692
13692
  } else
13693
13693
  // If we received an HTTP_ERROR but there's no status code,
13694
13694
  // it's most probably a connection issue
13695
- o(new FirestoreError(C.UNAVAILABLE, "Connection failed."));
13695
+ o(new FirestoreError(D.UNAVAILABLE, "Connection failed."));
13696
13696
  break;
13697
13697
 
13698
13698
  default:
13699
13699
  fail();
13700
13700
  }
13701
13701
  } finally {
13702
- __PRIVATE_logDebug(me, `RPC '${e}' ${i} completed.`);
13702
+ __PRIVATE_logDebug(Ve, `RPC '${e}' ${i} completed.`);
13703
13703
  }
13704
13704
  }));
13705
13705
  const a = JSON.stringify(r);
13706
- __PRIVATE_logDebug(me, `RPC '${e}' ${i} sending request:`, r), _.send(t, "POST", a, n, 15);
13706
+ __PRIVATE_logDebug(Ve, `RPC '${e}' ${i} sending request:`, r), _.send(t, "POST", a, n, 15);
13707
13707
  }));
13708
13708
  }
13709
13709
  vo(e, t, n) {
@@ -13731,9 +13731,8 @@ class __PRIVATE_RestConnection {
13731
13731
  forceLongPolling: this.forceLongPolling,
13732
13732
  detectBufferingProxy: this.autoDetectLongPolling
13733
13733
  }, a = this.longPollingOptions.timeoutSeconds;
13734
- void 0 !== a && (_.longPollingTimeout = Math.round(1e3 * a)), this.useFetchStreams && (
13735
- // TODO(b/307942499): switch to `useFetchStreams` once WebChannel is fixed.
13736
- _.xmlHttpFactory = new webchannelWrapper.FetchXmlHttpFactory({})), this.bo(_.initMessageHeaders, t, n),
13734
+ void 0 !== a && (_.longPollingTimeout = Math.round(1e3 * a)), this.useFetchStreams && (_.useFetchStreams = !0),
13735
+ this.bo(_.initMessageHeaders, t, n),
13737
13736
  // Sending the custom headers we just added to request.initMessageHeaders
13738
13737
  // (Authorization, etc.) will trigger the browser to make a CORS preflight
13739
13738
  // request because the XHR will no longer meet the criteria for a "simple"
@@ -13745,7 +13744,7 @@ class __PRIVATE_RestConnection {
13745
13744
  // which is recognized by the webchannel backend.
13746
13745
  _.encodeInitMessageHeaders = !0;
13747
13746
  const u = i.join("");
13748
- __PRIVATE_logDebug(me, `Creating RPC '${e}' stream ${r}: ${u}`, _);
13747
+ __PRIVATE_logDebug(Ve, `Creating RPC '${e}' stream ${r}: ${u}`, _);
13749
13748
  const c = s.createWebChannel(u, _);
13750
13749
  // WebChannel supports sending the first message with the handshake - saving
13751
13750
  // a network round trip. However, it will have to call send in the same
@@ -13758,8 +13757,8 @@ class __PRIVATE_RestConnection {
13758
13757
  // on a closed stream
13759
13758
  const P = new __PRIVATE_StreamBridge({
13760
13759
  co: t => {
13761
- h ? __PRIVATE_logDebug(me, `Not sending because RPC '${e}' stream ${r} is closed:`, t) : (l || (__PRIVATE_logDebug(me, `Opening RPC '${e}' stream ${r} transport.`),
13762
- c.open(), l = !0), __PRIVATE_logDebug(me, `RPC '${e}' stream ${r} sending:`, t),
13760
+ h ? __PRIVATE_logDebug(Ve, `Not sending because RPC '${e}' stream ${r} is closed:`, t) : (l || (__PRIVATE_logDebug(Ve, `Opening RPC '${e}' stream ${r} transport.`),
13761
+ c.open(), l = !0), __PRIVATE_logDebug(Ve, `RPC '${e}' stream ${r} sending:`, t),
13763
13762
  c.send(t));
13764
13763
  },
13765
13764
  lo: () => c.close()
@@ -13781,13 +13780,13 @@ class __PRIVATE_RestConnection {
13781
13780
  // Note that eventually this function could go away if we are confident
13782
13781
  // enough the code is exception free.
13783
13782
  return __PRIVATE_unguardedEventListen(c, webchannelWrapper.WebChannel.EventType.OPEN, (() => {
13784
- h || __PRIVATE_logDebug(me, `RPC '${e}' stream ${r} transport opened.`);
13783
+ h || __PRIVATE_logDebug(Ve, `RPC '${e}' stream ${r} transport opened.`);
13785
13784
  })), __PRIVATE_unguardedEventListen(c, webchannelWrapper.WebChannel.EventType.CLOSE, (() => {
13786
- h || (h = !0, __PRIVATE_logDebug(me, `RPC '${e}' stream ${r} transport closed`),
13785
+ h || (h = !0, __PRIVATE_logDebug(Ve, `RPC '${e}' stream ${r} transport closed`),
13787
13786
  P.Ro());
13788
13787
  })), __PRIVATE_unguardedEventListen(c, webchannelWrapper.WebChannel.EventType.ERROR, (t => {
13789
- h || (h = !0, __PRIVATE_logWarn(me, `RPC '${e}' stream ${r} transport errored:`, t),
13790
- P.Ro(new FirestoreError(C.UNAVAILABLE, "The operation could not be completed")));
13788
+ h || (h = !0, __PRIVATE_logWarn(Ve, `RPC '${e}' stream ${r} transport errored:`, t),
13789
+ P.Ro(new FirestoreError(D.UNAVAILABLE, "The operation could not be completed")));
13791
13790
  })), __PRIVATE_unguardedEventListen(c, webchannelWrapper.WebChannel.EventType.MESSAGE, (t => {
13792
13791
  var n;
13793
13792
  if (!h) {
@@ -13800,7 +13799,7 @@ class __PRIVATE_RestConnection {
13800
13799
  // Use any because msgData.error is not typed.
13801
13800
  const s = i, o = s.error || (null === (n = s[0]) || void 0 === n ? void 0 : n.error);
13802
13801
  if (o) {
13803
- __PRIVATE_logDebug(me, `RPC '${e}' stream ${r} received error:`, o);
13802
+ __PRIVATE_logDebug(Ve, `RPC '${e}' stream ${r} received error:`, o);
13804
13803
  // error.status will be a string like 'OK' or 'NOT_FOUND'.
13805
13804
  const t = o.status;
13806
13805
  let n =
@@ -13813,16 +13812,16 @@ class __PRIVATE_RestConnection {
13813
13812
  function __PRIVATE_mapCodeFromRpcStatus(e) {
13814
13813
  // lookup by string
13815
13814
  // eslint-disable-next-line @typescript-eslint/no-explicit-any
13816
- const t = ue[e];
13815
+ const t = ae[e];
13817
13816
  if (void 0 !== t) return __PRIVATE_mapCodeFromRpcCode(t);
13818
13817
  }(t), i = o.message;
13819
- void 0 === n && (n = C.INTERNAL, i = "Unknown error status: " + t + " with message " + o.message),
13818
+ void 0 === n && (n = D.INTERNAL, i = "Unknown error status: " + t + " with message " + o.message),
13820
13819
  // Mark closed so no further events are propagated
13821
13820
  h = !0, P.Ro(new FirestoreError(n, i)), c.close();
13822
- } else __PRIVATE_logDebug(me, `RPC '${e}' stream ${r} received:`, i), P.Vo(i);
13821
+ } else __PRIVATE_logDebug(Ve, `RPC '${e}' stream ${r} received:`, i), P.Vo(i);
13823
13822
  }
13824
13823
  })), __PRIVATE_unguardedEventListen(o, webchannelWrapper.Event.STAT_EVENT, (t => {
13825
- t.stat === webchannelWrapper.Stat.PROXY ? __PRIVATE_logDebug(me, `RPC '${e}' stream ${r} detected buffering proxy`) : t.stat === webchannelWrapper.Stat.NOPROXY && __PRIVATE_logDebug(me, `RPC '${e}' stream ${r} detected no buffering proxy`);
13824
+ t.stat === webchannelWrapper.Stat.PROXY ? __PRIVATE_logDebug(Ve, `RPC '${e}' stream ${r} detected buffering proxy`) : t.stat === webchannelWrapper.Stat.NOPROXY && __PRIVATE_logDebug(Ve, `RPC '${e}' stream ${r} detected no buffering proxy`);
13826
13825
  })), setTimeout((() => {
13827
13826
  // Technically we could/should wait for the WebChannel opened event,
13828
13827
  // but because we want to send the first message with the WebChannel
@@ -14146,10 +14145,10 @@ class __PRIVATE_PersistentStream {
14146
14145
  // underlying stream), guaranteeing they won't execute.
14147
14146
  this.Uo++, 4 /* PersistentStreamState.Error */ !== e ?
14148
14147
  // If this is an intentional close ensure we don't delay our next connection attempt.
14149
- this.zo.reset() : t && t.code === C.RESOURCE_EXHAUSTED ? (
14148
+ this.zo.reset() : t && t.code === D.RESOURCE_EXHAUSTED ? (
14150
14149
  // Log the error. (Probably either 'quota exceeded' or 'max queue length reached'.)
14151
14150
  __PRIVATE_logError(t.toString()), __PRIVATE_logError("Using maximum backoff delay to prevent overloading the backend."),
14152
- this.zo.Lo()) : t && t.code === C.UNAUTHENTICATED && 3 /* PersistentStreamState.Healthy */ !== this.state && (
14151
+ this.zo.Lo()) : t && t.code === D.UNAUTHENTICATED && 3 /* PersistentStreamState.Healthy */ !== this.state && (
14153
14152
  // "unauthenticated" error means the token was rejected. This should rarely
14154
14153
  // happen since both Auth and AppCheck ensure a sufficient TTL when we
14155
14154
  // request a token. If a user manually resets their system clock this can
@@ -14185,7 +14184,7 @@ class __PRIVATE_PersistentStream {
14185
14184
  this.s_(e, n);
14186
14185
  }), (t => {
14187
14186
  e((() => {
14188
- const e = new FirestoreError(C.UNKNOWN, "Fetching auth token failed: " + t.message);
14187
+ const e = new FirestoreError(D.UNKNOWN, "Fetching auth token failed: " + t.message);
14189
14188
  return this.o_(e);
14190
14189
  }));
14191
14190
  }));
@@ -14352,7 +14351,7 @@ class __PRIVATE_PersistentStream {
14352
14351
  * Sends an initial streamToken to the server, performing the handshake
14353
14352
  * required to make the StreamingWrite RPC work. Subsequent
14354
14353
  * calls should wait until onHandshakeComplete was called.
14355
- */ d_() {
14354
+ */ E_() {
14356
14355
  // TODO(dimond): Support stream resumption. We intentionally do not set the
14357
14356
  // stream token on the handshake, ignoring any stream token we might have.
14358
14357
  const e = {};
@@ -14395,25 +14394,25 @@ class __PRIVATE_PersistentStream {
14395
14394
  class __PRIVATE_DatastoreImpl extends class Datastore {} {
14396
14395
  constructor(e, t, n, r) {
14397
14396
  super(), this.authCredentials = e, this.appCheckCredentials = t, this.connection = n,
14398
- this.serializer = r, this.E_ = !1;
14397
+ this.serializer = r, this.d_ = !1;
14399
14398
  }
14400
14399
  A_() {
14401
- if (this.E_) throw new FirestoreError(C.FAILED_PRECONDITION, "The client has already been terminated.");
14400
+ if (this.d_) throw new FirestoreError(D.FAILED_PRECONDITION, "The client has already been terminated.");
14402
14401
  }
14403
14402
  /** Invokes the provided RPC with auth and AppCheck tokens. */ wo(e, t, n) {
14404
14403
  return this.A_(), Promise.all([ this.authCredentials.getToken(), this.appCheckCredentials.getToken() ]).then((([r, i]) => this.connection.wo(e, t, n, r, i))).catch((e => {
14405
- throw "FirebaseError" === e.name ? (e.code === C.UNAUTHENTICATED && (this.authCredentials.invalidateToken(),
14406
- this.appCheckCredentials.invalidateToken()), e) : new FirestoreError(C.UNKNOWN, e.toString());
14404
+ throw "FirebaseError" === e.name ? (e.code === D.UNAUTHENTICATED && (this.authCredentials.invalidateToken(),
14405
+ this.appCheckCredentials.invalidateToken()), e) : new FirestoreError(D.UNKNOWN, e.toString());
14407
14406
  }));
14408
14407
  }
14409
14408
  /** Invokes the provided RPC with streamed results with auth and AppCheck tokens. */ Co(e, t, n, r) {
14410
14409
  return this.A_(), Promise.all([ this.authCredentials.getToken(), this.appCheckCredentials.getToken() ]).then((([i, s]) => this.connection.Co(e, t, n, i, s, r))).catch((e => {
14411
- throw "FirebaseError" === e.name ? (e.code === C.UNAUTHENTICATED && (this.authCredentials.invalidateToken(),
14412
- this.appCheckCredentials.invalidateToken()), e) : new FirestoreError(C.UNKNOWN, e.toString());
14410
+ throw "FirebaseError" === e.name ? (e.code === D.UNAUTHENTICATED && (this.authCredentials.invalidateToken(),
14411
+ this.appCheckCredentials.invalidateToken()), e) : new FirestoreError(D.UNKNOWN, e.toString());
14413
14412
  }));
14414
14413
  }
14415
14414
  terminate() {
14416
- this.E_ = !0;
14415
+ this.d_ = !0;
14417
14416
  }
14418
14417
  }
14419
14418
 
@@ -14873,7 +14872,7 @@ function __PRIVATE_startWriteStream(e) {
14873
14872
  }
14874
14873
 
14875
14874
  async function __PRIVATE_onWriteStreamOpen(e) {
14876
- __PRIVATE_ensureWriteStream(e).d_();
14875
+ __PRIVATE_ensureWriteStream(e).E_();
14877
14876
  }
14878
14877
 
14879
14878
  async function __PRIVATE_onWriteHandshakeComplete(e) {
@@ -14899,7 +14898,7 @@ async function __PRIVATE_onWriteStreamClose(e, t) {
14899
14898
  // Only handle permanent errors here. If it's transient, just let the retry
14900
14899
  // logic kick in.
14901
14900
  if (function __PRIVATE_isPermanentWriteError(e) {
14902
- return __PRIVATE_isPermanentError(e) && e !== C.ABORTED;
14901
+ return __PRIVATE_isPermanentError(e) && e !== D.ABORTED;
14903
14902
  }(t.code)) {
14904
14903
  // This was a permanent error, the request itself was the problem
14905
14904
  // so it's not going to succeed if we resend it.
@@ -15080,7 +15079,7 @@ class DelayedOperation {
15080
15079
  * As long as the operation has not yet been run, calling cancel() provides a
15081
15080
  * guarantee that the operation will not be run.
15082
15081
  */ cancel(e) {
15083
- null !== this.timerHandle && (this.clearTimeout(), this.deferred.reject(new FirestoreError(C.CANCELLED, "Operation cancelled" + (e ? ": " + e : ""))));
15082
+ null !== this.timerHandle && (this.clearTimeout(), this.deferred.reject(new FirestoreError(D.CANCELLED, "Operation cancelled" + (e ? ": " + e : ""))));
15084
15083
  }
15085
15084
  handleDelayElapsed() {
15086
15085
  this.asyncQueue.enqueueAndForget((() => null !== this.timerHandle ? (this.clearTimeout(),
@@ -15096,7 +15095,7 @@ class DelayedOperation {
15096
15095
  * Returns a FirestoreError that can be surfaced to the user if the provided
15097
15096
  * error is an IndexedDbTransactionError. Re-throws the error otherwise.
15098
15097
  */ function __PRIVATE_wrapInUserErrorIfRecoverable(e, t) {
15099
- if (__PRIVATE_logError("AsyncQueue", `${t}: ${e}`), __PRIVATE_isIndexedDbTransactionError(e)) return new FirestoreError(C.UNAVAILABLE, `${t}: ${e}`);
15098
+ if (__PRIVATE_logError("AsyncQueue", `${t}: ${e}`), __PRIVATE_isIndexedDbTransactionError(e)) return new FirestoreError(D.UNAVAILABLE, `${t}: ${e}`);
15100
15099
  throw e;
15101
15100
  }
15102
15101
 
@@ -15716,19 +15715,22 @@ class __PRIVATE_RemovedLimboDocument {
15716
15715
  * Updates the view with the given ViewDocumentChanges and optionally updates
15717
15716
  * limbo docs and sync state from the provided target change.
15718
15717
  * @param docChanges - The set of changes to make to the view's docs.
15719
- * @param updateLimboDocuments - Whether to update limbo documents based on
15718
+ * @param limboResolutionEnabled - Whether to update limbo documents based on
15720
15719
  * this change.
15721
15720
  * @param targetChange - A target change to apply for computing limbo docs and
15722
15721
  * sync state.
15722
+ * @param targetIsPendingReset - Whether the target is pending to reset due to
15723
+ * existence filter mismatch. If not explicitly specified, it is treated
15724
+ * equivalently to `false`.
15723
15725
  * @returns A new ViewChange with the given docs, changes, and sync state.
15724
15726
  */
15725
15727
  // PORTING NOTE: The iOS/Android clients always compute limbo document changes.
15726
- applyChanges(e, t, n) {
15727
- const r = this.aa;
15728
+ applyChanges(e, t, n, r) {
15729
+ const i = this.aa;
15728
15730
  this.aa = e.aa, this.mutatedKeys = e.mutatedKeys;
15729
15731
  // Sort changes based on type and query comparator
15730
- const i = e.la.L_();
15731
- i.sort(((e, t) => function __PRIVATE_compareChangeType(e, t) {
15732
+ const s = e.la.L_();
15733
+ s.sort(((e, t) => function __PRIVATE_compareChangeType(e, t) {
15732
15734
  const order = e => {
15733
15735
  switch (e) {
15734
15736
  case 0 /* ChangeType.Added */ :
@@ -15765,18 +15767,20 @@ class __PRIVATE_RemovedLimboDocument {
15765
15767
  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
15766
15768
  * See the License for the specific language governing permissions and
15767
15769
  * limitations under the License.
15768
- */ (e.type, t.type) || this._a(e.doc, t.doc))), this.Pa(n);
15769
- const s = t ? this.Ia() : [], o = 0 === this.oa.size && this.current ? 1 /* SyncState.Synced */ : 0 /* SyncState.Local */ , _ = o !== this.sa;
15770
- if (this.sa = o, 0 !== i.length || _) {
15770
+ */ (e.type, t.type) || this._a(e.doc, t.doc))), this.Pa(n), r = null != r && r;
15771
+ const o = t && !r ? this.Ia() : [], _ = 0 === this.oa.size && this.current && !r ? 1 /* SyncState.Synced */ : 0 /* SyncState.Local */ , a = _ !== this.sa;
15772
+ // We are at synced state if there is no limbo docs are waiting to be resolved, view is current
15773
+ // with the backend, and the query is not pending to reset due to existence filter mismatch.
15774
+ if (this.sa = _, 0 !== s.length || a) {
15771
15775
  return {
15772
- snapshot: new ViewSnapshot(this.query, e.aa, r, i, e.mutatedKeys, 0 /* SyncState.Local */ === o, _,
15776
+ snapshot: new ViewSnapshot(this.query, e.aa, i, s, e.mutatedKeys, 0 /* SyncState.Local */ === _, a,
15773
15777
  /* excludesMetadataChanges= */ !1, !!n && n.resumeToken.approximateByteSize() > 0),
15774
- Ta: s
15778
+ Ta: o
15775
15779
  };
15776
15780
  }
15777
15781
  // no changes
15778
15782
  return {
15779
- Ta: s
15783
+ Ta: o
15780
15784
  };
15781
15785
  }
15782
15786
  /**
@@ -15794,13 +15798,13 @@ class __PRIVATE_RemovedLimboDocument {
15794
15798
  mutatedKeys: this.mutatedKeys,
15795
15799
  Zi: !1
15796
15800
  },
15797
- /* updateLimboDocuments= */ !1)) : {
15801
+ /* limboResolutionEnabled= */ !1)) : {
15798
15802
  Ta: []
15799
15803
  };
15800
15804
  }
15801
15805
  /**
15802
15806
  * Returns whether the doc for the given key should be in limbo.
15803
- */ da(e) {
15807
+ */ Ea(e) {
15804
15808
  // If the remote end says it's part of this query, it's not in limbo.
15805
15809
  return !this.ia.has(e) && (
15806
15810
  // The local store doesn't think it's a result, so it shouldn't be in limbo.
@@ -15820,7 +15824,7 @@ class __PRIVATE_RemovedLimboDocument {
15820
15824
  // updating many documents.
15821
15825
  const e = this.oa;
15822
15826
  this.oa = __PRIVATE_documentKeySet(), this.aa.forEach((e => {
15823
- this.da(e.key) && (this.oa = this.oa.add(e.key));
15827
+ this.Ea(e.key) && (this.oa = this.oa.add(e.key));
15824
15828
  }));
15825
15829
  // Diff the new limbo docs with the old limbo docs.
15826
15830
  const t = [];
@@ -15850,10 +15854,10 @@ class __PRIVATE_RemovedLimboDocument {
15850
15854
  * @returns The ViewChange that resulted from this synchronization.
15851
15855
  */
15852
15856
  // PORTING NOTE: Multi-tab only.
15853
- Ea(e) {
15857
+ da(e) {
15854
15858
  this.ia = e.ls, this.oa = __PRIVATE_documentKeySet();
15855
15859
  const t = this.ca(e.documents);
15856
- return this.applyChanges(t, /*updateLimboDocuments=*/ !0);
15860
+ return this.applyChanges(t, /* limboResolutionEnabled= */ !0);
15857
15861
  }
15858
15862
  /**
15859
15863
  * Returns a view snapshot as if this query was just listened to. Contains
@@ -15997,13 +16001,13 @@ async function __PRIVATE_syncEngineListen(e, t) {
15997
16001
  // didn't lose any good docs that had been past the limit.
15998
16002
  i = await __PRIVATE_localStoreExecuteQuery(e.localStore, t.query,
15999
16003
  /* usePreviousResults= */ !1).then((({documents: e}) => t.view.ca(e, i))));
16000
- const s = r && r.targetChanges.get(t.targetId), o = t.view.applyChanges(i,
16001
- /* updateLimboDocuments= */ e.isPrimaryClient, s);
16002
- return __PRIVATE_updateTrackedLimbos(e, t.targetId, o.Ta), o.snapshot;
16004
+ const s = r && r.targetChanges.get(t.targetId), o = r && null != r.targetMismatches.get(t.targetId), _ = t.view.applyChanges(i,
16005
+ /* limboResolutionEnabled= */ e.isPrimaryClient, s, o);
16006
+ return __PRIVATE_updateTrackedLimbos(e, t.targetId, _.Ta), _.snapshot;
16003
16007
  }(e, t, n, r);
16004
16008
  const s = await __PRIVATE_localStoreExecuteQuery(e.localStore, t,
16005
16009
  /* usePreviousResults= */ !0), o = new __PRIVATE_View(t, s.ls), _ = o.ca(s.documents), a = TargetChange.createSynthesizedTargetChangeForCurrentChange(n, r && "Offline" /* OnlineState.Offline */ !== e.onlineState, i), u = o.applyChanges(_,
16006
- /* updateLimboDocuments= */ e.isPrimaryClient, a);
16010
+ /* limboResolutionEnabled= */ e.isPrimaryClient, a);
16007
16011
  __PRIVATE_updateTrackedLimbos(e, n, u.Ta);
16008
16012
  const c = new __PRIVATE_QueryView(t, n, o);
16009
16013
  return e.ma.set(t, c), e.fa.has(n) ? e.fa.get(n).push(t) : e.fa.set(n, [ t ]), u.snapshot;
@@ -16376,7 +16380,7 @@ async function __PRIVATE_syncEngineHandleCredentialChange(e, t) {
16376
16380
  function __PRIVATE_rejectOutstandingPendingWritesCallbacks(e, t) {
16377
16381
  e.ba.forEach((e => {
16378
16382
  e.forEach((e => {
16379
- e.reject(new FirestoreError(C.CANCELLED, t));
16383
+ e.reject(new FirestoreError(D.CANCELLED, t));
16380
16384
  }));
16381
16385
  })), e.ba.clear();
16382
16386
  }(n, "'waitForPendingWrites' promise is rejected due to a user change."),
@@ -16405,7 +16409,7 @@ function __PRIVATE_syncEngineGetRemoteKeysForTarget(e, t) {
16405
16409
  * from persistence.
16406
16410
  */ async function __PRIVATE_synchronizeViewAndComputeSnapshot(e, t) {
16407
16411
  const n = __PRIVATE_debugCast(e), r = await __PRIVATE_localStoreExecuteQuery(n.localStore, t.query,
16408
- /* usePreviousResults= */ !0), i = t.view.Ea(r);
16412
+ /* usePreviousResults= */ !0), i = t.view.da(r);
16409
16413
  return n.isPrimaryClient && __PRIVATE_updateTrackedLimbos(n, t.targetId, i.Ta),
16410
16414
  i;
16411
16415
  }
@@ -16805,7 +16809,7 @@ class __PRIVATE_LruGcMemoryOfflineComponentProvider extends MemoryOfflineCompone
16805
16809
  }
16806
16810
  createSharedClientState(e) {
16807
16811
  const t = __PRIVATE_getWindow();
16808
- if (!__PRIVATE_WebStorageSharedClientState.D(t)) throw new FirestoreError(C.UNIMPLEMENTED, "IndexedDB persistence is only available on platforms that support LocalStorage.");
16812
+ if (!__PRIVATE_WebStorageSharedClientState.D(t)) throw new FirestoreError(D.UNIMPLEMENTED, "IndexedDB persistence is only available on platforms that support LocalStorage.");
16809
16813
  const n = __PRIVATE_indexedDbStoragePrefix(e.databaseInfo.databaseId, e.databaseInfo.persistenceKey);
16810
16814
  return new __PRIVATE_WebStorageSharedClientState(t, e.asyncQueue, n, e.clientId, e.initialUser);
16811
16815
  }
@@ -17142,7 +17146,7 @@ class Transaction$2 {
17142
17146
  this.writtenDocs = new Set;
17143
17147
  }
17144
17148
  async lookup(e) {
17145
- if (this.ensureCommitNotCalled(), this.mutations.length > 0) throw new FirestoreError(C.INVALID_ARGUMENT, "Firestore transactions require all reads to be executed before all writes.");
17149
+ if (this.ensureCommitNotCalled(), this.mutations.length > 0) throw new FirestoreError(D.INVALID_ARGUMENT, "Firestore transactions require all reads to be executed before all writes.");
17146
17150
  const t = await async function __PRIVATE_invokeBatchGetDocumentsRpc(e, t) {
17147
17151
  const n = __PRIVATE_debugCast(e), r = __PRIVATE_getEncodedDatabaseId(n.serializer) + "/documents", i = {
17148
17152
  documents: t.map((e => __PRIVATE_toName(n.serializer, e)))
@@ -17203,7 +17207,7 @@ class Transaction$2 {
17203
17207
  if (n) {
17204
17208
  if (!t.isEqual(n))
17205
17209
  // This transaction will fail no matter what.
17206
- throw new FirestoreError(C.ABORTED, "Document version changed between two reads.");
17210
+ throw new FirestoreError(D.ABORTED, "Document version changed between two reads.");
17207
17211
  } else this.readVersions.set(e.key.toString(), t);
17208
17212
  }
17209
17213
  /**
@@ -17230,7 +17234,7 @@ class Transaction$2 {
17230
17234
  // express that to the backend, we have to validate locally.
17231
17235
  // Note: this can change once we can send separate verify writes in the
17232
17236
  // transaction.
17233
- throw new FirestoreError(C.INVALID_ARGUMENT, "Can't update a document that doesn't exist.");
17237
+ throw new FirestoreError(D.INVALID_ARGUMENT, "Can't update a document that doesn't exist.");
17234
17238
  // Document exists, base precondition on document update time.
17235
17239
  return Precondition.updateTime(t);
17236
17240
  }
@@ -17371,7 +17375,7 @@ class FirestoreClient {
17371
17375
  * Checks that the client has not been terminated. Ensures that other methods on //
17372
17376
  * this class cannot be called after the client is terminated. //
17373
17377
  */ verifyNotTerminated() {
17374
- if (this.asyncQueue.isShuttingDown) throw new FirestoreError(C.FAILED_PRECONDITION, "The client has already been terminated.");
17378
+ if (this.asyncQueue.isShuttingDown) throw new FirestoreError(D.FAILED_PRECONDITION, "The client has already been terminated.");
17375
17379
  }
17376
17380
  terminate() {
17377
17381
  this.asyncQueue.enterRestrictedMode();
@@ -17421,7 +17425,7 @@ async function __PRIVATE_setOnlineComponentProvider(e, t) {
17421
17425
  * Decides whether the provided error allows us to gracefully disable
17422
17426
  * persistence (as opposed to crashing the client).
17423
17427
  */ function __PRIVATE_canFallbackFromIndexedDbError(e) {
17424
- return "FirebaseError" === e.name ? e.code === C.FAILED_PRECONDITION || e.code === C.UNIMPLEMENTED : !("undefined" != typeof DOMException && e instanceof DOMException) || (
17428
+ return "FirebaseError" === e.name ? e.code === D.FAILED_PRECONDITION || e.code === D.UNIMPLEMENTED : !("undefined" != typeof DOMException && e instanceof DOMException) || (
17425
17429
  // When the browser is out of quota we could get either quota exceeded
17426
17430
  // or an aborted error depending on whether the error happened during
17427
17431
  // schema migration.
@@ -17513,7 +17517,7 @@ async function __PRIVATE_getEventManager(e) {
17513
17517
  const n = __PRIVATE_debugCast(e);
17514
17518
  return n.persistence.runTransaction("read document", "readonly", (e => n.localDocuments.getDocument(e, t)));
17515
17519
  }(e, t);
17516
- r.isFoundDocument() ? n.resolve(r) : r.isNoDocument() ? n.resolve(null) : n.reject(new FirestoreError(C.UNAVAILABLE, "Failed to get document from cache. (However, this document may exist on the server. Run again without setting 'source' in the GetOptions to attempt to retrieve the document from the server.)"));
17520
+ r.isFoundDocument() ? n.resolve(r) : r.isNoDocument() ? n.resolve(null) : n.reject(new FirestoreError(D.UNAVAILABLE, "Failed to get document from cache. (However, this document may exist on the server. Run again without setting 'source' in the GetOptions to attempt to retrieve the document from the server.)"));
17517
17521
  } catch (e) {
17518
17522
  const r = __PRIVATE_wrapInUserErrorIfRecoverable(e, `Failed to get document '${t} from cache`);
17519
17523
  n.reject(r);
@@ -17542,7 +17546,7 @@ function __PRIVATE_firestoreClientGetDocumentViaSnapshotListener(e, t, n = {}) {
17542
17546
  // the server so we can deliver that even when you're
17543
17547
  // offline 2) Actually reject the Promise in the online case
17544
17548
  // if the document doesn't exist.
17545
- i.reject(new FirestoreError(C.UNAVAILABLE, "Failed to get document because the client is offline.")) : _ && s.fromCache && r && "server" === r.source ? i.reject(new FirestoreError(C.UNAVAILABLE, 'Failed to get document from server. (However, this document does exist in the local cache. Run again without setting source to "server" to retrieve the cached document.)')) : i.resolve(s);
17549
+ i.reject(new FirestoreError(D.UNAVAILABLE, "Failed to get document because the client is offline.")) : _ && s.fromCache && r && "server" === r.source ? i.reject(new FirestoreError(D.UNAVAILABLE, 'Failed to get document from server. (However, this document does exist in the local cache. Run again without setting source to "server" to retrieve the cached document.)')) : i.resolve(s);
17546
17550
  },
17547
17551
  error: e => i.reject(e)
17548
17552
  }), o = new __PRIVATE_QueryListener(__PRIVATE_newQueryForPath(n.path), s, {
@@ -17559,7 +17563,7 @@ function __PRIVATE_firestoreClientGetDocumentsFromLocalCache(e, t) {
17559
17563
  try {
17560
17564
  const r = await __PRIVATE_localStoreExecuteQuery(e, t,
17561
17565
  /* usePreviousResults= */ !0), i = new __PRIVATE_View(t, r.ls), s = i.ca(r.documents), o = i.applyChanges(s,
17562
- /* updateLimboDocuments= */ !1);
17566
+ /* limboResolutionEnabled= */ !1);
17563
17567
  n.resolve(o.snapshot);
17564
17568
  } catch (e) {
17565
17569
  const r = __PRIVATE_wrapInUserErrorIfRecoverable(e, `Failed to execute query '${t} against cache`);
@@ -17579,7 +17583,7 @@ function __PRIVATE_firestoreClientGetDocumentsViaSnapshotListener(e, t, n = {})
17579
17583
  next: n => {
17580
17584
  // Remove query first before passing event to user to avoid
17581
17585
  // user actions affecting the now stale query.
17582
- t.enqueueAndForget((() => __PRIVATE_eventManagerUnlisten(e, o))), n.fromCache && "server" === r.source ? i.reject(new FirestoreError(C.UNAVAILABLE, 'Failed to get documents from server. (However, these documents may exist in the local cache. Run again without setting source to "server" to retrieve the cached documents.)')) : i.resolve(n);
17586
+ t.enqueueAndForget((() => __PRIVATE_eventManagerUnlisten(e, o))), n.fromCache && "server" === r.source ? i.reject(new FirestoreError(D.UNAVAILABLE, 'Failed to get documents from server. (However, these documents may exist in the local cache. Run again without setting source to "server" to retrieve the cached documents.)')) : i.resolve(n);
17583
17587
  },
17584
17588
  error: e => i.reject(e)
17585
17589
  }), o = new __PRIVATE_QueryListener(n, s, {
@@ -17779,7 +17783,7 @@ function __PRIVATE_cloneLongPollingOptions(e) {
17779
17783
  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
17780
17784
  * See the License for the specific language governing permissions and
17781
17785
  * limitations under the License.
17782
- */ const fe = new Map;
17786
+ */ const me = new Map;
17783
17787
 
17784
17788
  /**
17785
17789
  * An instance map that ensures only one Datastore exists per Firestore
@@ -17802,28 +17806,28 @@ function __PRIVATE_cloneLongPollingOptions(e) {
17802
17806
  * limitations under the License.
17803
17807
  */
17804
17808
  function __PRIVATE_validateNonEmptyArgument(e, t, n) {
17805
- if (!n) throw new FirestoreError(C.INVALID_ARGUMENT, `Function ${e}() cannot be called with an empty ${t}.`);
17809
+ if (!n) throw new FirestoreError(D.INVALID_ARGUMENT, `Function ${e}() cannot be called with an empty ${t}.`);
17806
17810
  }
17807
17811
 
17808
17812
  /**
17809
17813
  * Validates that two boolean options are not set at the same time.
17810
17814
  * @internal
17811
17815
  */ function __PRIVATE_validateIsNotUsedTogether(e, t, n, r) {
17812
- if (!0 === t && !0 === r) throw new FirestoreError(C.INVALID_ARGUMENT, `${e} and ${n} cannot be used together.`);
17816
+ if (!0 === t && !0 === r) throw new FirestoreError(D.INVALID_ARGUMENT, `${e} and ${n} cannot be used together.`);
17813
17817
  }
17814
17818
 
17815
17819
  /**
17816
17820
  * Validates that `path` refers to a document (indicated by the fact it contains
17817
17821
  * an even numbers of segments).
17818
17822
  */ function __PRIVATE_validateDocumentPath(e) {
17819
- if (!DocumentKey.isDocumentKey(e)) throw new FirestoreError(C.INVALID_ARGUMENT, `Invalid document reference. Document references must have an even number of segments, but ${e} has ${e.length}.`);
17823
+ if (!DocumentKey.isDocumentKey(e)) throw new FirestoreError(D.INVALID_ARGUMENT, `Invalid document reference. Document references must have an even number of segments, but ${e} has ${e.length}.`);
17820
17824
  }
17821
17825
 
17822
17826
  /**
17823
17827
  * Validates that `path` refers to a collection (indicated by the fact it
17824
17828
  * contains an odd numbers of segments).
17825
17829
  */ function __PRIVATE_validateCollectionPath(e) {
17826
- if (DocumentKey.isDocumentKey(e)) throw new FirestoreError(C.INVALID_ARGUMENT, `Invalid collection reference. Collection references must have an odd number of segments, but ${e} has ${e.length}.`);
17830
+ if (DocumentKey.isDocumentKey(e)) throw new FirestoreError(D.INVALID_ARGUMENT, `Invalid collection reference. Collection references must have an odd number of segments, but ${e} has ${e.length}.`);
17827
17831
  }
17828
17832
 
17829
17833
  /**
@@ -17867,17 +17871,17 @@ t) {
17867
17871
  // Unwrap Compat types
17868
17872
  // eslint-disable-next-line @typescript-eslint/no-explicit-any
17869
17873
  e = e._delegate), !(e instanceof t)) {
17870
- if (t.name === e.constructor.name) throw new FirestoreError(C.INVALID_ARGUMENT, "Type does not match the expected instance. Did you pass a reference from a different Firestore SDK?");
17874
+ if (t.name === e.constructor.name) throw new FirestoreError(D.INVALID_ARGUMENT, "Type does not match the expected instance. Did you pass a reference from a different Firestore SDK?");
17871
17875
  {
17872
17876
  const n = __PRIVATE_valueDescription(e);
17873
- throw new FirestoreError(C.INVALID_ARGUMENT, `Expected type '${t.name}', but it was: ${n}`);
17877
+ throw new FirestoreError(D.INVALID_ARGUMENT, `Expected type '${t.name}', but it was: ${n}`);
17874
17878
  }
17875
17879
  }
17876
17880
  return e;
17877
17881
  }
17878
17882
 
17879
17883
  function __PRIVATE_validatePositiveNumber(e, t) {
17880
- if (t <= 0) throw new FirestoreError(C.INVALID_ARGUMENT, `Function ${e}() requires a positive number, but it was: ${t}.`);
17884
+ if (t <= 0) throw new FirestoreError(D.INVALID_ARGUMENT, `Function ${e}() requires a positive number, but it was: ${t}.`);
17881
17885
  }
17882
17886
 
17883
17887
  /**
@@ -17906,12 +17910,12 @@ class FirestoreSettingsImpl {
17906
17910
  constructor(e) {
17907
17911
  var t, n;
17908
17912
  if (void 0 === e.host) {
17909
- if (void 0 !== e.ssl) throw new FirestoreError(C.INVALID_ARGUMENT, "Can't provide ssl option if host option is not set");
17913
+ if (void 0 !== e.ssl) throw new FirestoreError(D.INVALID_ARGUMENT, "Can't provide ssl option if host option is not set");
17910
17914
  this.host = "firestore.googleapis.com", this.ssl = true;
17911
17915
  } else this.host = e.host, this.ssl = null === (t = e.ssl) || void 0 === t || t;
17912
17916
  if (this.credentials = e.credentials, this.ignoreUndefinedProperties = !!e.ignoreUndefinedProperties,
17913
17917
  this.localCache = e.localCache, void 0 === e.cacheSizeBytes) this.cacheSizeBytes = 41943040; else {
17914
- if (-1 !== e.cacheSizeBytes && e.cacheSizeBytes < 1048576) throw new FirestoreError(C.INVALID_ARGUMENT, "cacheSizeBytes must be at least 1048576");
17918
+ if (-1 !== e.cacheSizeBytes && e.cacheSizeBytes < 1048576) throw new FirestoreError(D.INVALID_ARGUMENT, "cacheSizeBytes must be at least 1048576");
17915
17919
  this.cacheSizeBytes = e.cacheSizeBytes;
17916
17920
  }
17917
17921
  __PRIVATE_validateIsNotUsedTogether("experimentalForceLongPolling", e.experimentalForceLongPolling, "experimentalAutoDetectLongPolling", e.experimentalAutoDetectLongPolling),
@@ -17923,9 +17927,9 @@ class FirestoreSettingsImpl {
17923
17927
  this.experimentalLongPollingOptions = __PRIVATE_cloneLongPollingOptions(null !== (n = e.experimentalLongPollingOptions) && void 0 !== n ? n : {}),
17924
17928
  function __PRIVATE_validateLongPollingOptions(e) {
17925
17929
  if (void 0 !== e.timeoutSeconds) {
17926
- if (isNaN(e.timeoutSeconds)) throw new FirestoreError(C.INVALID_ARGUMENT, `invalid long polling timeout: ${e.timeoutSeconds} (must not be NaN)`);
17927
- if (e.timeoutSeconds < 5) throw new FirestoreError(C.INVALID_ARGUMENT, `invalid long polling timeout: ${e.timeoutSeconds} (minimum allowed value is 5)`);
17928
- if (e.timeoutSeconds > 30) throw new FirestoreError(C.INVALID_ARGUMENT, `invalid long polling timeout: ${e.timeoutSeconds} (maximum allowed value is 30)`);
17930
+ if (isNaN(e.timeoutSeconds)) throw new FirestoreError(D.INVALID_ARGUMENT, `invalid long polling timeout: ${e.timeoutSeconds} (must not be NaN)`);
17931
+ if (e.timeoutSeconds < 5) throw new FirestoreError(D.INVALID_ARGUMENT, `invalid long polling timeout: ${e.timeoutSeconds} (minimum allowed value is 5)`);
17932
+ if (e.timeoutSeconds > 30) throw new FirestoreError(D.INVALID_ARGUMENT, `invalid long polling timeout: ${e.timeoutSeconds} (maximum allowed value is 30)`);
17929
17933
  }
17930
17934
  }
17931
17935
  /**
@@ -17972,7 +17976,7 @@ class Firestore$1 {
17972
17976
  * The {@link @firebase/app#FirebaseApp} associated with this `Firestore` service
17973
17977
  * instance.
17974
17978
  */ get app() {
17975
- if (!this._app) throw new FirestoreError(C.FAILED_PRECONDITION, "Firestore was not initialized using the Firebase SDK. 'app' is not available");
17979
+ if (!this._app) throw new FirestoreError(D.FAILED_PRECONDITION, "Firestore was not initialized using the Firebase SDK. 'app' is not available");
17976
17980
  return this._app;
17977
17981
  }
17978
17982
  get _initialized() {
@@ -17982,7 +17986,7 @@ class Firestore$1 {
17982
17986
  return void 0 !== this._terminateTask;
17983
17987
  }
17984
17988
  _setSettings(e) {
17985
- if (this._settingsFrozen) throw new FirestoreError(C.FAILED_PRECONDITION, "Firestore has already been started and its settings can no longer be changed. You can only modify settings before calling any other methods on a Firestore object.");
17989
+ if (this._settingsFrozen) throw new FirestoreError(D.FAILED_PRECONDITION, "Firestore has already been started and its settings can no longer be changed. You can only modify settings before calling any other methods on a Firestore object.");
17986
17990
  this._settings = new FirestoreSettingsImpl(e), void 0 !== e.credentials && (this._authCredentials = function __PRIVATE_makeAuthCredentialsProvider(e) {
17987
17991
  if (!e) return new __PRIVATE_EmptyAuthCredentialsProvider;
17988
17992
  switch (e.type) {
@@ -17993,7 +17997,7 @@ class Firestore$1 {
17993
17997
  return e.client;
17994
17998
 
17995
17999
  default:
17996
- throw new FirestoreError(C.INVALID_ARGUMENT, "makeAuthCredentialsProvider failed due to invalid credential type");
18000
+ throw new FirestoreError(D.INVALID_ARGUMENT, "makeAuthCredentialsProvider failed due to invalid credential type");
17997
18001
  }
17998
18002
  }(e.credentials));
17999
18003
  }
@@ -18025,8 +18029,8 @@ class Firestore$1 {
18025
18029
  * when the `Firestore` instance is terminated.
18026
18030
  */
18027
18031
  return function __PRIVATE_removeComponents(e) {
18028
- const t = fe.get(e);
18029
- t && (__PRIVATE_logDebug("ComponentProvider", "Removing Datastore"), fe.delete(e),
18032
+ const t = me.get(e);
18033
+ t && (__PRIVATE_logDebug("ComponentProvider", "Removing Datastore"), me.delete(e),
18030
18034
  t.terminate());
18031
18035
  }(this), Promise.resolve();
18032
18036
  }
@@ -18058,7 +18062,7 @@ class Firestore$1 {
18058
18062
  // invalid field "uid" and missing field "sub" / "user_id".)
18059
18063
  t = util.createMockUserToken(r.mockUserToken, null === (i = e._app) || void 0 === i ? void 0 : i.options.projectId);
18060
18064
  const s = r.mockUserToken.sub || r.mockUserToken.user_id;
18061
- if (!s) throw new FirestoreError(C.INVALID_ARGUMENT, "mockUserToken must contain 'sub' or 'user_id' field!");
18065
+ if (!s) throw new FirestoreError(D.INVALID_ARGUMENT, "mockUserToken must contain 'sub' or 'user_id' field!");
18062
18066
  n = new User(s);
18063
18067
  }
18064
18068
  e._authCredentials = new __PRIVATE_EmulatorAuthCredentialsProvider(new __PRIVATE_OAuthToken(t, n));
@@ -18178,7 +18182,7 @@ function collection(e, t, ...n) {
18178
18182
  return __PRIVATE_validateCollectionPath(r), new CollectionReference(e, /* converter= */ null, r);
18179
18183
  }
18180
18184
  {
18181
- if (!(e instanceof DocumentReference || e instanceof CollectionReference)) throw new FirestoreError(C.INVALID_ARGUMENT, "Expected first argument to collection() to be a CollectionReference, a DocumentReference or FirebaseFirestore");
18185
+ if (!(e instanceof DocumentReference || e instanceof CollectionReference)) throw new FirestoreError(D.INVALID_ARGUMENT, "Expected first argument to collection() to be a CollectionReference, a DocumentReference or FirebaseFirestore");
18182
18186
  const r = e._path.child(ResourcePath.fromString(t, ...n));
18183
18187
  return __PRIVATE_validateCollectionPath(r), new CollectionReference(e.firestore,
18184
18188
  /* converter= */ null, r);
@@ -18199,7 +18203,7 @@ function collection(e, t, ...n) {
18199
18203
  * @returns The created `Query`.
18200
18204
  */ function collectionGroup(e, t) {
18201
18205
  if (e = __PRIVATE_cast(e, Firestore$1), __PRIVATE_validateNonEmptyArgument("collectionGroup", "collection id", t),
18202
- t.indexOf("/") >= 0) throw new FirestoreError(C.INVALID_ARGUMENT, `Invalid collection ID '${t}' passed to function collectionGroup(). Collection IDs must not contain '/'.`);
18206
+ t.indexOf("/") >= 0) throw new FirestoreError(D.INVALID_ARGUMENT, `Invalid collection ID '${t}' passed to function collectionGroup(). Collection IDs must not contain '/'.`);
18203
18207
  return new Query(e,
18204
18208
  /* converter= */ null, function __PRIVATE_newQueryForCollectionGroup(e) {
18205
18209
  return new __PRIVATE_QueryImpl(ResourcePath.emptyPath(), e);
@@ -18217,7 +18221,7 @@ function doc(e, t, ...n) {
18217
18221
  /* converter= */ null, new DocumentKey(r));
18218
18222
  }
18219
18223
  {
18220
- if (!(e instanceof DocumentReference || e instanceof CollectionReference)) throw new FirestoreError(C.INVALID_ARGUMENT, "Expected first argument to collection() to be a CollectionReference, a DocumentReference or FirebaseFirestore");
18224
+ if (!(e instanceof DocumentReference || e instanceof CollectionReference)) throw new FirestoreError(D.INVALID_ARGUMENT, "Expected first argument to collection() to be a CollectionReference, a DocumentReference or FirebaseFirestore");
18221
18225
  const r = e._path.child(ResourcePath.fromString(t, ...n));
18222
18226
  return __PRIVATE_validateDocumentPath(r), new DocumentReference(e.firestore, e instanceof CollectionReference ? e.converter : null, new DocumentKey(r));
18223
18227
  }
@@ -18577,7 +18581,7 @@ class LoadBundleTask {
18577
18581
  * Constant used to indicate the LRU garbage collection should be disabled.
18578
18582
  * Set this value as the `cacheSizeBytes` on the settings passed to the
18579
18583
  * {@link Firestore} instance.
18580
- */ const ge = -1;
18584
+ */ const fe = -1;
18581
18585
 
18582
18586
  /**
18583
18587
  * The Cloud Firestore service interface.
@@ -18621,10 +18625,10 @@ class LoadBundleTask {
18621
18625
  identifier: n
18622
18626
  }), i = r.getOptions(n);
18623
18627
  if (util.deepEqual(i, t)) return e;
18624
- throw new FirestoreError(C.FAILED_PRECONDITION, "initializeFirestore() has already been called with different options. To avoid this error, call initializeFirestore() with the same options as when it was originally called, or call getFirestore() to return the already initialized instance.");
18628
+ throw new FirestoreError(D.FAILED_PRECONDITION, "initializeFirestore() has already been called with different options. To avoid this error, call initializeFirestore() with the same options as when it was originally called, or call getFirestore() to return the already initialized instance.");
18625
18629
  }
18626
- if (void 0 !== t.cacheSizeBytes && void 0 !== t.localCache) throw new FirestoreError(C.INVALID_ARGUMENT, "cache and cacheSizeBytes cannot be specified at the same time as cacheSizeBytes willbe deprecated. Instead, specify the cache size in the cache object");
18627
- if (void 0 !== t.cacheSizeBytes && -1 !== t.cacheSizeBytes && t.cacheSizeBytes < 1048576) throw new FirestoreError(C.INVALID_ARGUMENT, "cacheSizeBytes must be at least 1048576");
18630
+ if (void 0 !== t.cacheSizeBytes && void 0 !== t.localCache) throw new FirestoreError(D.INVALID_ARGUMENT, "cache and cacheSizeBytes cannot be specified at the same time as cacheSizeBytes willbe deprecated. Instead, specify the cache size in the cache object");
18631
+ if (void 0 !== t.cacheSizeBytes && -1 !== t.cacheSizeBytes && t.cacheSizeBytes < 1048576) throw new FirestoreError(D.INVALID_ARGUMENT, "cacheSizeBytes must be at least 1048576");
18628
18632
  return r.initialize({
18629
18633
  options: t,
18630
18634
  instanceIdentifier: n
@@ -18693,7 +18697,7 @@ function __PRIVATE_configureFirestore(e) {
18693
18697
  */ function enableIndexedDbPersistence(e, t) {
18694
18698
  __PRIVATE_verifyNotInitialized(e = __PRIVATE_cast(e, Firestore));
18695
18699
  const n = ensureFirestoreConfigured(e);
18696
- if (n._uninitializedComponentsProvider) throw new FirestoreError(C.FAILED_PRECONDITION, "SDK cache is already specified.");
18700
+ if (n._uninitializedComponentsProvider) throw new FirestoreError(D.FAILED_PRECONDITION, "SDK cache is already specified.");
18697
18701
  __PRIVATE_logWarn("enableIndexedDbPersistence() will be deprecated in the future, you can use `FirestoreSettings.cache` instead.");
18698
18702
  const r = e._freezeSettings(), i = new OnlineComponentProvider;
18699
18703
  return __PRIVATE_setPersistenceProviders(n, i, new __PRIVATE_IndexedDbOfflineComponentProvider(i, r.cacheSizeBytes, null == t ? void 0 : t.forceOwnership));
@@ -18727,7 +18731,7 @@ function __PRIVATE_configureFirestore(e) {
18727
18731
  */ function enableMultiTabIndexedDbPersistence(e) {
18728
18732
  __PRIVATE_verifyNotInitialized(e = __PRIVATE_cast(e, Firestore));
18729
18733
  const t = ensureFirestoreConfigured(e);
18730
- if (t._uninitializedComponentsProvider) throw new FirestoreError(C.FAILED_PRECONDITION, "SDK cache is already specified.");
18734
+ if (t._uninitializedComponentsProvider) throw new FirestoreError(D.FAILED_PRECONDITION, "SDK cache is already specified.");
18731
18735
  __PRIVATE_logWarn("enableMultiTabIndexedDbPersistence() will be deprecated in the future, you can use `FirestoreSettings.cache` instead.");
18732
18736
  const n = e._freezeSettings(), r = new OnlineComponentProvider;
18733
18737
  return __PRIVATE_setPersistenceProviders(t, r, new __PRIVATE_MultiTabOfflineComponentProvider(r, n.cacheSizeBytes));
@@ -18775,7 +18779,7 @@ function __PRIVATE_configureFirestore(e) {
18775
18779
  * @returns A `Promise` that is resolved when the persistent storage is
18776
18780
  * cleared. Otherwise, the promise is rejected with an error.
18777
18781
  */ function clearIndexedDbPersistence(e) {
18778
- if (e._initialized && !e._terminated) throw new FirestoreError(C.FAILED_PRECONDITION, "Persistence can only be cleared before a Firestore instance is initialized or after it is terminated.");
18782
+ if (e._initialized && !e._terminated) throw new FirestoreError(D.FAILED_PRECONDITION, "Persistence can only be cleared before a Firestore instance is initialized or after it is terminated.");
18779
18783
  const t = new __PRIVATE_Deferred;
18780
18784
  return e._queue.enqueueAndForgetEvenWhileRestricted((async () => {
18781
18785
  try {
@@ -18889,7 +18893,7 @@ function __PRIVATE_configureFirestore(e) {
18889
18893
  }
18890
18894
 
18891
18895
  function __PRIVATE_verifyNotInitialized(e) {
18892
- if (e._initialized || e._terminated) throw new FirestoreError(C.FAILED_PRECONDITION, "Firestore has already been started and persistence can no longer be enabled. You can only enable persistence before calling any other methods on a Firestore object.");
18896
+ if (e._initialized || e._terminated) throw new FirestoreError(D.FAILED_PRECONDITION, "Firestore has already been started and persistence can no longer be enabled. You can only enable persistence before calling any other methods on a Firestore object.");
18893
18897
  }
18894
18898
 
18895
18899
  /**
@@ -18998,7 +19002,7 @@ class AggregateField {
18998
19002
  try {
18999
19003
  return new Bytes(ByteString.fromBase64String(e));
19000
19004
  } catch (e) {
19001
- throw new FirestoreError(C.INVALID_ARGUMENT, "Failed to construct data from Base64 string: " + e);
19005
+ throw new FirestoreError(D.INVALID_ARGUMENT, "Failed to construct data from Base64 string: " + e);
19002
19006
  }
19003
19007
  }
19004
19008
  /**
@@ -19070,7 +19074,7 @@ class AggregateField {
19070
19074
  * @param fieldNames - A list of field names.
19071
19075
  */
19072
19076
  constructor(...e) {
19073
- for (let t = 0; t < e.length; ++t) if (0 === e[t].length) throw new FirestoreError(C.INVALID_ARGUMENT, "Invalid field name at argument $(i + 1). Field names must not be empty.");
19077
+ for (let t = 0; t < e.length; ++t) if (0 === e[t].length) throw new FirestoreError(D.INVALID_ARGUMENT, "Invalid field name at argument $(i + 1). Field names must not be empty.");
19074
19078
  this._internalPath = new FieldPath$1(e);
19075
19079
  }
19076
19080
  /**
@@ -19149,8 +19153,8 @@ class AggregateField {
19149
19153
  * @param longitude - The longitude as number between -180 and 180.
19150
19154
  */
19151
19155
  constructor(e, t) {
19152
- if (!isFinite(e) || e < -90 || e > 90) throw new FirestoreError(C.INVALID_ARGUMENT, "Latitude must be a number between -90 and 90, but was: " + e);
19153
- if (!isFinite(t) || t < -180 || t > 180) throw new FirestoreError(C.INVALID_ARGUMENT, "Longitude must be a number between -180 and 180, but was: " + t);
19156
+ if (!isFinite(e) || e < -90 || e > 90) throw new FirestoreError(D.INVALID_ARGUMENT, "Latitude must be a number between -90 and 90, but was: " + e);
19157
+ if (!isFinite(t) || t < -180 || t > 180) throw new FirestoreError(D.INVALID_ARGUMENT, "Longitude must be a number between -180 and 180, but was: " + t);
19154
19158
  this._lat = e, this._long = t;
19155
19159
  }
19156
19160
  /**
@@ -19200,7 +19204,7 @@ class AggregateField {
19200
19204
  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
19201
19205
  * See the License for the specific language governing permissions and
19202
19206
  * limitations under the License.
19203
- */ const pe = /^__.*__$/;
19207
+ */ const ge = /^__.*__$/;
19204
19208
 
19205
19209
  /** The result of parsing document data (e.g. for a setData call). */ class ParsedSetData {
19206
19210
  constructor(e, t, n) {
@@ -19274,11 +19278,11 @@ function __PRIVATE_isWrite(e) {
19274
19278
  /** Returns a new context with the specified settings overwritten. */ Tu(e) {
19275
19279
  return new __PRIVATE_ParseContextImpl(Object.assign(Object.assign({}, this.settings), e), this.databaseId, this.serializer, this.ignoreUndefinedProperties, this.fieldTransforms, this.fieldMask);
19276
19280
  }
19277
- du(e) {
19281
+ Eu(e) {
19278
19282
  var t;
19279
19283
  const n = null === (t = this.path) || void 0 === t ? void 0 : t.child(e), r = this.Tu({
19280
19284
  path: n,
19281
- Eu: !1
19285
+ du: !1
19282
19286
  });
19283
19287
  return r.Au(e), r;
19284
19288
  }
@@ -19286,7 +19290,7 @@ function __PRIVATE_isWrite(e) {
19286
19290
  var t;
19287
19291
  const n = null === (t = this.path) || void 0 === t ? void 0 : t.child(e), r = this.Tu({
19288
19292
  path: n,
19289
- Eu: !1
19293
+ du: !1
19290
19294
  });
19291
19295
  return r.Pu(), r;
19292
19296
  }
@@ -19295,7 +19299,7 @@ function __PRIVATE_isWrite(e) {
19295
19299
  // undefined.
19296
19300
  return this.Tu({
19297
19301
  path: void 0,
19298
- Eu: !0
19302
+ du: !0
19299
19303
  });
19300
19304
  }
19301
19305
  mu(e) {
@@ -19311,7 +19315,7 @@ function __PRIVATE_isWrite(e) {
19311
19315
  }
19312
19316
  Au(e) {
19313
19317
  if (0 === e.length) throw this.mu("Document fields must not be empty");
19314
- if (__PRIVATE_isWrite(this.Iu) && pe.test(e)) throw this.mu('Document fields cannot begin and end with "__"');
19318
+ if (__PRIVATE_isWrite(this.Iu) && ge.test(e)) throw this.mu('Document fields cannot begin and end with "__"');
19315
19319
  }
19316
19320
  }
19317
19321
 
@@ -19328,7 +19332,7 @@ function __PRIVATE_isWrite(e) {
19328
19332
  methodName: t,
19329
19333
  gu: n,
19330
19334
  path: FieldPath$1.emptyPath(),
19331
- Eu: !1,
19335
+ du: !1,
19332
19336
  fu: r
19333
19337
  }, this.databaseId, this.serializer, this.ignoreUndefinedProperties);
19334
19338
  }
@@ -19348,7 +19352,7 @@ function __PRIVATE_newUserDataReader(e) {
19348
19352
  const e = [];
19349
19353
  for (const r of s.mergeFields) {
19350
19354
  const i = __PRIVATE_fieldPathFromArgument$1(t, r, n);
19351
- if (!o.contains(i)) throw new FirestoreError(C.INVALID_ARGUMENT, `Field '${i}' is specified in your field mask but missing from your input data.`);
19355
+ if (!o.contains(i)) throw new FirestoreError(D.INVALID_ARGUMENT, `Field '${i}' is specified in your field mask but missing from your input data.`);
19352
19356
  __PRIVATE_fieldMaskContains(e, i) || e.push(i);
19353
19357
  }
19354
19358
  a = new FieldMask(e), u = o.fieldTransforms.filter((e => a.covers(e.field)));
@@ -19388,7 +19392,7 @@ class __PRIVATE_DeleteFieldValueImpl extends FieldValue {
19388
19392
  Iu: 3 /* UserDataSource.Argument */ ,
19389
19393
  gu: t.settings.gu,
19390
19394
  methodName: e._methodName,
19391
- Eu: n
19395
+ du: n
19392
19396
  }, t.databaseId, t.serializer, t.ignoreUndefinedProperties);
19393
19397
  }
19394
19398
 
@@ -19468,7 +19472,7 @@ class __PRIVATE_NumericIncrementFieldValueImpl extends FieldValue {
19468
19472
 
19469
19473
  /** Parse update data from a list of field/value arguments. */ function __PRIVATE_parseUpdateVarargs(e, t, n, r, i, s) {
19470
19474
  const o = e.pu(1 /* UserDataSource.Update */ , t, n), _ = [ __PRIVATE_fieldPathFromArgument$1(t, r, n) ], a = [ i ];
19471
- if (s.length % 2 != 0) throw new FirestoreError(C.INVALID_ARGUMENT, `Function ${t}() needs to be called with an even number of arguments that alternate between field names and values.`);
19475
+ if (s.length % 2 != 0) throw new FirestoreError(D.INVALID_ARGUMENT, `Function ${t}() needs to be called with an even number of arguments that alternate between field names and values.`);
19472
19476
  for (let e = 0; e < s.length; e += 2) _.push(__PRIVATE_fieldPathFromArgument$1(t, s[e])),
19473
19477
  a.push(s[e + 1]);
19474
19478
  const u = [], c = ObjectValue.empty();
@@ -19553,7 +19557,7 @@ class __PRIVATE_NumericIncrementFieldValueImpl extends FieldValue {
19553
19557
  // the set of values to be included for the IN query) that may directly
19554
19558
  // contain additional arrays (each representing an individual field
19555
19559
  // value), so we disable this validation.
19556
- if (t.settings.Eu && 4 /* UserDataSource.ArrayArgument */ !== t.Iu) throw t.mu("Nested arrays are not supported");
19560
+ if (t.settings.du && 4 /* UserDataSource.ArrayArgument */ !== t.Iu) throw t.mu("Nested arrays are not supported");
19557
19561
  return function __PRIVATE_parseArray(e, t) {
19558
19562
  const n = [];
19559
19563
  let r = 0;
@@ -19632,7 +19636,7 @@ function __PRIVATE_parseObject(e, t) {
19632
19636
  // If we encounter an empty object, we explicitly add it to the update
19633
19637
  // mask to ensure that the server creates a map entry.
19634
19638
  t.path && t.path.length > 0 && t.fieldMask.push(t.path) : forEach(e, ((e, r) => {
19635
- const i = __PRIVATE_parseData(r, t.du(e));
19639
+ const i = __PRIVATE_parseData(r, t.Eu(e));
19636
19640
  null != i && (n[e] = i);
19637
19641
  })), {
19638
19642
  mapValue: {
@@ -19669,7 +19673,7 @@ function __PRIVATE_validatePlainObject(e, t, n) {
19669
19673
 
19670
19674
  /**
19671
19675
  * Matches any characters in a field path string that are reserved.
19672
- */ const ye = new RegExp("[~\\*/\\[\\]]");
19676
+ */ const pe = new RegExp("[~\\*/\\[\\]]");
19673
19677
 
19674
19678
  /**
19675
19679
  * Wraps fromDotSeparatedString with an error message about the method that
@@ -19680,7 +19684,7 @@ function __PRIVATE_validatePlainObject(e, t, n) {
19680
19684
  * @param targetDoc - The document against which the field path will be
19681
19685
  * evaluated.
19682
19686
  */ function __PRIVATE_fieldPathFromDotSeparatedString(e, t, n) {
19683
- if (t.search(ye) >= 0) throw __PRIVATE_createError(`Invalid field path (${t}). Paths must not contain '~', '*', '/', '[', or ']'`, e,
19687
+ if (t.search(pe) >= 0) throw __PRIVATE_createError(`Invalid field path (${t}). Paths must not contain '~', '*', '/', '[', or ']'`, e,
19684
19688
  /* hasConverter= */ !1,
19685
19689
  /* path= */ void 0, n);
19686
19690
  try {
@@ -19698,7 +19702,7 @@ function __PRIVATE_createError(e, t, n, r, i) {
19698
19702
  n && (_ += " (via `toFirestore()`)"), _ += ". ";
19699
19703
  let a = "";
19700
19704
  return (s || o) && (a += " (found", s && (a += ` in field ${r}`), o && (a += ` in document ${i}`),
19701
- a += ")"), new FirestoreError(C.INVALID_ARGUMENT, _ + e + a);
19705
+ a += ")"), new FirestoreError(D.INVALID_ARGUMENT, _ + e + a);
19702
19706
  }
19703
19707
 
19704
19708
  /** Checks `haystack` if FieldPath `needle` is present. Runs in O(n). */ function __PRIVATE_fieldMaskContains(e, t) {
@@ -19835,7 +19839,7 @@ function __PRIVATE_createError(e, t, n, r, i) {
19835
19839
  * See the License for the specific language governing permissions and
19836
19840
  * limitations under the License.
19837
19841
  */ function __PRIVATE_validateHasExplicitOrderByForLimitToLast(e) {
19838
- if ("L" /* LimitType.Last */ === e.limitType && 0 === e.explicitOrderBy.length) throw new FirestoreError(C.UNIMPLEMENTED, "limitToLast() queries require specifying at least one orderBy() clause");
19842
+ if ("L" /* LimitType.Last */ === e.limitType && 0 === e.explicitOrderBy.length) throw new FirestoreError(D.UNIMPLEMENTED, "limitToLast() queries require specifying at least one orderBy() clause");
19839
19843
  }
19840
19844
 
19841
19845
  /**
@@ -19856,7 +19860,7 @@ function query(e, t, ...n) {
19856
19860
  let r = [];
19857
19861
  t instanceof AppliableConstraint && r.push(t), r = r.concat(n), function __PRIVATE_validateQueryConstraintArray(e) {
19858
19862
  const t = e.filter((e => e instanceof QueryCompositeFilterConstraint)).length, n = e.filter((e => e instanceof QueryFieldFilterConstraint)).length;
19859
- if (t > 1 || t > 0 && n > 0) throw new FirestoreError(C.INVALID_ARGUMENT, "InvalidQuery. When using composite filters, you cannot use more than one filter at the top level. Consider nesting the multiple filters within an `and(...)` statement. For example: change `query(query, where(...), or(...))` to `query(query, and(where(...), or(...)))`.");
19863
+ if (t > 1 || t > 0 && n > 0) throw new FirestoreError(D.INVALID_ARGUMENT, "InvalidQuery. When using composite filters, you cannot use more than one filter at the top level. Consider nesting the multiple filters within an `and(...)` statement. For example: change `query(query, where(...), or(...))` to `query(query, and(where(...), or(...)))`.");
19860
19864
  }
19861
19865
  /**
19862
19866
  * @license
@@ -19910,7 +19914,7 @@ function query(e, t, ...n) {
19910
19914
  const t = __PRIVATE_newUserDataReader(e.firestore), n = function __PRIVATE_newQueryFilter(e, t, n, r, i, s, o) {
19911
19915
  let _;
19912
19916
  if (i.isKeyField()) {
19913
- if ("array-contains" /* Operator.ARRAY_CONTAINS */ === s || "array-contains-any" /* Operator.ARRAY_CONTAINS_ANY */ === s) throw new FirestoreError(C.INVALID_ARGUMENT, `Invalid Query. You can't perform '${s}' queries on documentId().`);
19917
+ if ("array-contains" /* Operator.ARRAY_CONTAINS */ === s || "array-contains-any" /* Operator.ARRAY_CONTAINS_ANY */ === s) throw new FirestoreError(D.INVALID_ARGUMENT, `Invalid Query. You can't perform '${s}' queries on documentId().`);
19914
19918
  if ("in" /* Operator.IN */ === s || "not-in" /* Operator.NOT_IN */ === s) {
19915
19919
  __PRIVATE_validateDisjunctiveFilterElements(o, s);
19916
19920
  const t = [];
@@ -20037,8 +20041,8 @@ function query(e, t, ...n) {
20037
20041
  }
20038
20042
  _apply(e) {
20039
20043
  const t = function __PRIVATE_newQueryOrderBy(e, t, n) {
20040
- if (null !== e.startAt) throw new FirestoreError(C.INVALID_ARGUMENT, "Invalid query. You must not call startAt() or startAfter() before calling orderBy().");
20041
- if (null !== e.endAt) throw new FirestoreError(C.INVALID_ARGUMENT, "Invalid query. You must not call endAt() or endBefore() before calling orderBy().");
20044
+ if (null !== e.startAt) throw new FirestoreError(D.INVALID_ARGUMENT, "Invalid query. You must not call startAt() or startAfter() before calling orderBy().");
20045
+ if (null !== e.endAt) throw new FirestoreError(D.INVALID_ARGUMENT, "Invalid query. You must not call endAt() or endBefore() before calling orderBy().");
20042
20046
  return new OrderBy(t, n);
20043
20047
  }
20044
20048
  /**
@@ -20196,7 +20200,7 @@ function endAt(...e) {
20196
20200
 
20197
20201
  /** Helper function to create a bound from a document or fields */ function __PRIVATE_newQueryBoundFromDocOrFields(e, t, n, r) {
20198
20202
  if (n[0] = util.getModularInstance(n[0]), n[0] instanceof DocumentSnapshot$1) return function __PRIVATE_newQueryBoundFromDocument(e, t, n, r, i) {
20199
- if (!r) throw new FirestoreError(C.NOT_FOUND, `Can't use a DocumentSnapshot that doesn't exist for ${n}().`);
20203
+ if (!r) throw new FirestoreError(D.NOT_FOUND, `Can't use a DocumentSnapshot that doesn't exist for ${n}().`);
20200
20204
  const s = [];
20201
20205
  // Because people expect to continue/end a query at the exact document
20202
20206
  // provided, we need to use the implicit sort order rather than the explicit
@@ -20207,10 +20211,10 @@ function endAt(...e) {
20207
20211
  // results.
20208
20212
  for (const n of __PRIVATE_queryNormalizedOrderBy(e)) if (n.field.isKeyField()) s.push(__PRIVATE_refValue(t, r.key)); else {
20209
20213
  const e = r.data.field(n.field);
20210
- if (__PRIVATE_isServerTimestamp(e)) throw new FirestoreError(C.INVALID_ARGUMENT, 'Invalid query. You are trying to start or end a query using a document for which the field "' + n.field + '" is an uncommitted server timestamp. (Since the value of this field is unknown, you cannot start/end a query with it.)');
20214
+ if (__PRIVATE_isServerTimestamp(e)) throw new FirestoreError(D.INVALID_ARGUMENT, 'Invalid query. You are trying to start or end a query using a document for which the field "' + n.field + '" is an uncommitted server timestamp. (Since the value of this field is unknown, you cannot start/end a query with it.)');
20211
20215
  if (null === e) {
20212
20216
  const e = n.field.canonicalString();
20213
- throw new FirestoreError(C.INVALID_ARGUMENT, `Invalid query. You are trying to start or end a query using a document for which the field '${e}' (used as the orderBy) does not exist.`);
20217
+ throw new FirestoreError(D.INVALID_ARGUMENT, `Invalid query. You are trying to start or end a query using a document for which the field '${e}' (used as the orderBy) does not exist.`);
20214
20218
  }
20215
20219
  s.push(e);
20216
20220
  }
@@ -20224,15 +20228,15 @@ function endAt(...e) {
20224
20228
  return function __PRIVATE_newQueryBoundFromFields(e, t, n, r, i, s) {
20225
20229
  // Use explicit order by's because it has to match the query the user made
20226
20230
  const o = e.explicitOrderBy;
20227
- if (i.length > o.length) throw new FirestoreError(C.INVALID_ARGUMENT, `Too many arguments provided to ${r}(). The number of arguments must be less than or equal to the number of orderBy() clauses`);
20231
+ if (i.length > o.length) throw new FirestoreError(D.INVALID_ARGUMENT, `Too many arguments provided to ${r}(). The number of arguments must be less than or equal to the number of orderBy() clauses`);
20228
20232
  const _ = [];
20229
20233
  for (let s = 0; s < i.length; s++) {
20230
20234
  const a = i[s];
20231
20235
  if (o[s].field.isKeyField()) {
20232
- if ("string" != typeof a) throw new FirestoreError(C.INVALID_ARGUMENT, `Invalid query. Expected a string for document ID in ${r}(), but got a ${typeof a}`);
20233
- if (!__PRIVATE_isCollectionGroupQuery(e) && -1 !== a.indexOf("/")) throw new FirestoreError(C.INVALID_ARGUMENT, `Invalid query. When querying a collection and ordering by documentId(), the value passed to ${r}() must be a plain document ID, but '${a}' contains a slash.`);
20236
+ if ("string" != typeof a) throw new FirestoreError(D.INVALID_ARGUMENT, `Invalid query. Expected a string for document ID in ${r}(), but got a ${typeof a}`);
20237
+ if (!__PRIVATE_isCollectionGroupQuery(e) && -1 !== a.indexOf("/")) throw new FirestoreError(D.INVALID_ARGUMENT, `Invalid query. When querying a collection and ordering by documentId(), the value passed to ${r}() must be a plain document ID, but '${a}' contains a slash.`);
20234
20238
  const n = e.path.child(ResourcePath.fromString(a));
20235
- if (!DocumentKey.isDocumentKey(n)) throw new FirestoreError(C.INVALID_ARGUMENT, `Invalid query. When querying a collection group and ordering by documentId(), the value passed to ${r}() must result in a valid document path, but '${n}' is not because it contains an odd number of segments.`);
20239
+ if (!DocumentKey.isDocumentKey(n)) throw new FirestoreError(D.INVALID_ARGUMENT, `Invalid query. When querying a collection group and ordering by documentId(), the value passed to ${r}() must result in a valid document path, but '${n}' is not because it contains an odd number of segments.`);
20236
20240
  const i = new DocumentKey(n);
20237
20241
  _.push(__PRIVATE_refValue(t, i));
20238
20242
  } else {
@@ -20252,21 +20256,21 @@ function endAt(...e) {
20252
20256
 
20253
20257
  function __PRIVATE_parseDocumentIdValue(e, t, n) {
20254
20258
  if ("string" == typeof (n = util.getModularInstance(n))) {
20255
- if ("" === n) throw new FirestoreError(C.INVALID_ARGUMENT, "Invalid query. When querying with documentId(), you must provide a valid document ID, but it was an empty string.");
20256
- if (!__PRIVATE_isCollectionGroupQuery(t) && -1 !== n.indexOf("/")) throw new FirestoreError(C.INVALID_ARGUMENT, `Invalid query. When querying a collection by documentId(), you must provide a plain document ID, but '${n}' contains a '/' character.`);
20259
+ if ("" === n) throw new FirestoreError(D.INVALID_ARGUMENT, "Invalid query. When querying with documentId(), you must provide a valid document ID, but it was an empty string.");
20260
+ if (!__PRIVATE_isCollectionGroupQuery(t) && -1 !== n.indexOf("/")) throw new FirestoreError(D.INVALID_ARGUMENT, `Invalid query. When querying a collection by documentId(), you must provide a plain document ID, but '${n}' contains a '/' character.`);
20257
20261
  const r = t.path.child(ResourcePath.fromString(n));
20258
- if (!DocumentKey.isDocumentKey(r)) throw new FirestoreError(C.INVALID_ARGUMENT, `Invalid query. When querying a collection group by documentId(), the value provided must result in a valid document path, but '${r}' is not because it has an odd number of segments (${r.length}).`);
20262
+ if (!DocumentKey.isDocumentKey(r)) throw new FirestoreError(D.INVALID_ARGUMENT, `Invalid query. When querying a collection group by documentId(), the value provided must result in a valid document path, but '${r}' is not because it has an odd number of segments (${r.length}).`);
20259
20263
  return __PRIVATE_refValue(e, new DocumentKey(r));
20260
20264
  }
20261
20265
  if (n instanceof DocumentReference) return __PRIVATE_refValue(e, n._key);
20262
- throw new FirestoreError(C.INVALID_ARGUMENT, `Invalid query. When querying with documentId(), you must provide a valid string or a DocumentReference, but it was: ${__PRIVATE_valueDescription(n)}.`);
20266
+ throw new FirestoreError(D.INVALID_ARGUMENT, `Invalid query. When querying with documentId(), you must provide a valid string or a DocumentReference, but it was: ${__PRIVATE_valueDescription(n)}.`);
20263
20267
  }
20264
20268
 
20265
20269
  /**
20266
20270
  * Validates that the value passed into a disjunctive filter satisfies all
20267
20271
  * array requirements.
20268
20272
  */ function __PRIVATE_validateDisjunctiveFilterElements(e, t) {
20269
- if (!Array.isArray(e) || 0 === e.length) throw new FirestoreError(C.INVALID_ARGUMENT, `Invalid Query. A non-empty array is required for '${t.toString()}' filters.`);
20273
+ if (!Array.isArray(e) || 0 === e.length) throw new FirestoreError(D.INVALID_ARGUMENT, `Invalid Query. A non-empty array is required for '${t.toString()}' filters.`);
20270
20274
  }
20271
20275
 
20272
20276
  /**
@@ -20300,11 +20304,11 @@ function __PRIVATE_parseDocumentIdValue(e, t, n) {
20300
20304
  }(t.op));
20301
20305
  if (null !== n)
20302
20306
  // Special case when it's a duplicate op to give a slightly clearer error message.
20303
- throw n === t.op ? new FirestoreError(C.INVALID_ARGUMENT, `Invalid query. You cannot use more than one '${t.op.toString()}' filter.`) : new FirestoreError(C.INVALID_ARGUMENT, `Invalid query. You cannot use '${t.op.toString()}' filters with '${n.toString()}' filters.`);
20307
+ throw n === t.op ? new FirestoreError(D.INVALID_ARGUMENT, `Invalid query. You cannot use more than one '${t.op.toString()}' filter.`) : new FirestoreError(D.INVALID_ARGUMENT, `Invalid query. You cannot use '${t.op.toString()}' filters with '${n.toString()}' filters.`);
20304
20308
  }
20305
20309
 
20306
20310
  function __PRIVATE_validateQueryFilterConstraint(e, t) {
20307
- if (!(t instanceof QueryFieldFilterConstraint || t instanceof QueryCompositeFilterConstraint)) throw new FirestoreError(C.INVALID_ARGUMENT, `Function ${e}() requires AppliableConstraints created with a call to 'where(...)', 'or(...)', or 'and(...)'.`);
20311
+ if (!(t instanceof QueryFieldFilterConstraint || t instanceof QueryCompositeFilterConstraint)) throw new FirestoreError(D.INVALID_ARGUMENT, `Function ${e}() requires AppliableConstraints created with a call to 'where(...)', 'or(...)', or 'and(...)'.`);
20308
20312
  }
20309
20313
 
20310
20314
  class AbstractUserDataWriter {
@@ -20676,7 +20680,7 @@ class __PRIVATE_LiteUserDataWriter extends AbstractUserDataWriter {
20676
20680
  * snapshot events.
20677
20681
  */ docChanges(e = {}) {
20678
20682
  const t = !!e.includeMetadataChanges;
20679
- if (t && this._snapshot.excludesMetadataChanges) throw new FirestoreError(C.INVALID_ARGUMENT, "To include metadata changes with your document changes, you must also pass { includeMetadataChanges:true } to onSnapshot().");
20683
+ if (t && this._snapshot.excludesMetadataChanges) throw new FirestoreError(D.INVALID_ARGUMENT, "To include metadata changes with your document changes, you must also pass { includeMetadataChanges:true } to onSnapshot().");
20680
20684
  return this._cachedChanges && this._cachedChangesIncludeMetadataChanges === t || (this._cachedChanges =
20681
20685
  /** Calculates the array of `DocumentChange`s for a given `ViewSnapshot`. */
20682
20686
  function __PRIVATE_changesFromSnapshot(e, t) {
@@ -21232,7 +21236,7 @@ class __PRIVATE_MultiTabManagerImpl {
21232
21236
  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
21233
21237
  * See the License for the specific language governing permissions and
21234
21238
  * limitations under the License.
21235
- */ const we = {
21239
+ */ const ye = {
21236
21240
  maxAttempts: 5
21237
21241
  };
21238
21242
 
@@ -21306,12 +21310,12 @@ class WriteBatch {
21306
21310
  return this._verifyNotCommitted(), this._committed = !0, this._mutations.length > 0 ? this._commitHandler(this._mutations) : Promise.resolve();
21307
21311
  }
21308
21312
  _verifyNotCommitted() {
21309
- if (this._committed) throw new FirestoreError(C.FAILED_PRECONDITION, "A write batch can no longer be used after commit() has been called.");
21313
+ if (this._committed) throw new FirestoreError(D.FAILED_PRECONDITION, "A write batch can no longer be used after commit() has been called.");
21310
21314
  }
21311
21315
  }
21312
21316
 
21313
21317
  function __PRIVATE_validateReference(e, t) {
21314
- if ((e = util.getModularInstance(e)).firestore !== t) throw new FirestoreError(C.INVALID_ARGUMENT, "Provided document reference is from a different Firestore instance.");
21318
+ if ((e = util.getModularInstance(e)).firestore !== t) throw new FirestoreError(D.INVALID_ARGUMENT, "Provided document reference is from a different Firestore instance.");
21315
21319
  return e;
21316
21320
  }
21317
21321
 
@@ -21444,9 +21448,9 @@ class Transaction extends class Transaction$1 {
21444
21448
  * rejected promise with the corresponding failure error is returned.
21445
21449
  */ function runTransaction(e, t, n) {
21446
21450
  e = __PRIVATE_cast(e, Firestore);
21447
- const r = Object.assign(Object.assign({}, we), n);
21451
+ const r = Object.assign(Object.assign({}, ye), n);
21448
21452
  !function __PRIVATE_validateTransactionOptions(e) {
21449
- if (e.maxAttempts < 1) throw new FirestoreError(C.INVALID_ARGUMENT, "Max attempts must be at least 1");
21453
+ if (e.maxAttempts < 1) throw new FirestoreError(D.INVALID_ARGUMENT, "Max attempts must be at least 1");
21450
21454
  }(r);
21451
21455
  return function __PRIVATE_firestoreClientTransaction(e, t, n) {
21452
21456
  const r = new __PRIVATE_Deferred;
@@ -21600,7 +21604,7 @@ class Transaction extends class Transaction$1 {
21600
21604
  try {
21601
21605
  return JSON.parse(e);
21602
21606
  } catch (e) {
21603
- throw new FirestoreError(C.INVALID_ARGUMENT, "Failed to parse JSON: " + (null == e ? void 0 : e.message));
21607
+ throw new FirestoreError(D.INVALID_ARGUMENT, "Failed to parse JSON: " + (null == e ? void 0 : e.message));
21604
21608
  }
21605
21609
  }(e) : e, n = [];
21606
21610
  if (Array.isArray(t.indexes)) for (const e of t.indexes) {
@@ -21617,7 +21621,7 @@ class Transaction extends class Transaction$1 {
21617
21621
  }
21618
21622
 
21619
21623
  function __PRIVATE_tryGetString(e, t) {
21620
- if ("string" != typeof e[t]) throw new FirestoreError(C.INVALID_ARGUMENT, "Missing string value for: " + t);
21624
+ if ("string" != typeof e[t]) throw new FirestoreError(D.INVALID_ARGUMENT, "Missing string value for: " + t);
21621
21625
  return e[t];
21622
21626
  }
21623
21627
 
@@ -21660,12 +21664,12 @@ function __PRIVATE_tryGetString(e, t) {
21660
21664
  */ function getPersistentCacheIndexManager(e) {
21661
21665
  var t;
21662
21666
  e = __PRIVATE_cast(e, Firestore);
21663
- const n = Se.get(e);
21667
+ const n = we.get(e);
21664
21668
  if (n) return n;
21665
21669
  const r = ensureFirestoreConfigured(e);
21666
21670
  if ("persistent" !== (null === (t = r._uninitializedComponentsProvider) || void 0 === t ? void 0 : t._offlineKind)) return null;
21667
21671
  const i = new PersistentCacheIndexManager(r);
21668
- return Se.set(e, i), i;
21672
+ return we.set(e, i), i;
21669
21673
  }
21670
21674
 
21671
21675
  /**
@@ -21708,7 +21712,7 @@ function __PRIVATE_setPersistentCacheIndexAutoCreationEnabled(e, t) {
21708
21712
  * Use a `WeakMap` so that the mapping will be automatically dropped when the
21709
21713
  * `Firestore` instance is garbage collected. This emulates a private member
21710
21714
  * as described in https://goo.gle/454yvug.
21711
- */ const Se = new WeakMap;
21715
+ */ const we = new WeakMap;
21712
21716
 
21713
21717
  /**
21714
21718
  * @license
@@ -21761,10 +21765,10 @@ function __PRIVATE_setPersistentCacheIndexAutoCreationEnabled(e, t) {
21761
21765
  this.Su = new Map;
21762
21766
  }
21763
21767
  static get instance() {
21764
- return be || (be = new __PRIVATE_TestingHooksSpiImpl, function __PRIVATE_setTestingHooksSpi(e) {
21765
- if (le) throw new Error("a TestingHooksSpi instance is already set");
21766
- le = e;
21767
- }(be)), be;
21768
+ return Se || (Se = new __PRIVATE_TestingHooksSpiImpl, function __PRIVATE_setTestingHooksSpi(e) {
21769
+ if (ce) throw new Error("a TestingHooksSpi instance is already set");
21770
+ ce = e;
21771
+ }(Se)), Se;
21768
21772
  }
21769
21773
  tt(e) {
21770
21774
  this.Su.forEach((t => t(e)));
@@ -21775,7 +21779,7 @@ function __PRIVATE_setPersistentCacheIndexAutoCreationEnabled(e, t) {
21775
21779
  }
21776
21780
  }
21777
21781
 
21778
- let be = null;
21782
+ let Se = null;
21779
21783
 
21780
21784
  /**
21781
21785
  * Cloud Firestore
@@ -21783,25 +21787,25 @@ let be = null;
21783
21787
  * @packageDocumentation
21784
21788
  */ !function __PRIVATE_registerFirestore(e, t = !0) {
21785
21789
  !function __PRIVATE_setSDKVersion(e) {
21786
- b = e;
21790
+ S = e;
21787
21791
  }(app.SDK_VERSION), app._registerComponent(new component.Component("firestore", ((e, {instanceIdentifier: n, options: r}) => {
21788
21792
  const i = e.getProvider("app").getImmediate(), s = new Firestore(new __PRIVATE_FirebaseAuthCredentialsProvider(e.getProvider("auth-internal")), new __PRIVATE_FirebaseAppCheckTokenProvider(e.getProvider("app-check-internal")), function __PRIVATE_databaseIdFromApp(e, t) {
21789
- if (!Object.prototype.hasOwnProperty.apply(e.options, [ "projectId" ])) throw new FirestoreError(C.INVALID_ARGUMENT, '"projectId" not provided in firebase.initializeApp.');
21793
+ if (!Object.prototype.hasOwnProperty.apply(e.options, [ "projectId" ])) throw new FirestoreError(D.INVALID_ARGUMENT, '"projectId" not provided in firebase.initializeApp.');
21790
21794
  return new DatabaseId(e.options.projectId, t);
21791
21795
  }(i, n), i);
21792
21796
  return r = Object.assign({
21793
21797
  useFetchStreams: t
21794
21798
  }, r), s._setSettings(r), s;
21795
- }), "PUBLIC").setMultipleInstances(!0)), app.registerVersion(S, "4.3.2-canary.bebecdaad", e),
21799
+ }), "PUBLIC").setMultipleInstances(!0)), app.registerVersion(w, "4.3.2-canary.e9ff107ee", e),
21796
21800
  // BUILD_TARGET will be replaced by values like esm5, esm2017, cjs5, etc during the compilation
21797
- app.registerVersion(S, "4.3.2-canary.bebecdaad", "cjs2017");
21801
+ app.registerVersion(w, "4.3.2-canary.e9ff107ee", "cjs2017");
21798
21802
  }();
21799
21803
 
21800
21804
  exports.AbstractUserDataWriter = AbstractUserDataWriter;
21801
21805
  exports.AggregateField = AggregateField;
21802
21806
  exports.AggregateQuerySnapshot = AggregateQuerySnapshot;
21803
21807
  exports.Bytes = Bytes;
21804
- exports.CACHE_SIZE_UNLIMITED = ge;
21808
+ exports.CACHE_SIZE_UNLIMITED = fe;
21805
21809
  exports.CollectionReference = CollectionReference;
21806
21810
  exports.DocumentReference = DocumentReference;
21807
21811
  exports.DocumentSnapshot = DocumentSnapshot;