File tree 5 files changed +73
-59
lines changed
src/firestore/FirestoreDocument
test/firestore/FirestoreDocument
5 files changed +73
-59
lines changed Load Diff This file was deleted.
Original file line number Diff line number Diff line change
1
+ /**
2
+ * @type {import("prettier").Config }
3
+ * @see https://prettier.io/docs/en/options.html
4
+ */
5
+ module . exports = {
6
+ proseWrap : "always" ,
7
+ } ;
Original file line number Diff line number Diff line change @@ -156,7 +156,9 @@ function deserializeFirestoreQuery(
156
156
const {
157
157
parentPath,
158
158
collectionId,
159
+ // `fieldFilters` has been renamed to `filters`
159
160
fieldFilters = [ ] ,
161
+ filters = fieldFilters ,
160
162
fieldOrders = [ ] ,
161
163
startAt,
162
164
endAt,
@@ -168,7 +170,7 @@ function deserializeFirestoreQuery(
168
170
const path = `${ parentPath . segments . join ( "/" ) } /${ collectionId } ` ;
169
171
let ref : Query = firestore . collection ( path ) ;
170
172
171
- fieldFilters . forEach ( ( { field, op, value } ) => {
173
+ filters . forEach ( ( { field, op, value } ) => {
172
174
if ( op === "OPERATOR_UNSPECIFIED" ) return ;
173
175
const path = field . segments . join ( "." ) ;
174
176
switch ( op ) {
Original file line number Diff line number Diff line change 1
1
import type { Timestamp } from "@google-cloud/firestore/build/src/timestamp" ;
2
2
import type { GeoPoint } from "@google-cloud/firestore/build/src/geo-point" ;
3
3
4
- // @ts -ignore
5
- import type {
6
- DocumentReference ,
7
- Query ,
8
- QueryOptions ,
9
- } from "@google-cloud/firestore/build/src/reference" ;
4
+ import type { Query } from "@google-cloud/firestore/build/src/reference/query" ;
5
+ import type { QueryOptions } from "@google-cloud/firestore/build/src/reference/query-options" ;
6
+ import type { DocumentReference } from "@google-cloud/firestore/build/src/reference/document-reference" ;
10
7
11
8
import * as protos from "@google-cloud/firestore/build/protos/firestore_v1_proto_api" ;
12
9
@@ -70,7 +67,9 @@ export interface SerializedQuery {
70
67
collectionId : string ;
71
68
// converter: any;
72
69
// allDescendants: boolean;
73
- fieldFilters : _FieldFilter [ ] ;
70
+ /** @deprecated */
71
+ fieldFilters ?: _FieldFilter [ ] ;
72
+ filters ?: _FieldFilter [ ] ;
74
73
fieldOrders : _FieldOrder [ ] ;
75
74
startAt ?: _QueryCursor ;
76
75
endAt ?: _QueryCursor ;
You can’t perform that action at this time.
0 commit comments