Skip to content

Commit 6449d10

Browse files
committed
Revert "Add databaseId for encoding and decoding keys"
This reverts commit 0ebabd5.
1 parent 0ebabd5 commit 6449d10

File tree

1 file changed

+4
-17
lines changed

1 file changed

+4
-17
lines changed

src/entity.ts

Lines changed: 4 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -282,7 +282,6 @@ export namespace entity {
282282
}
283283

284284
export interface KeyOptions {
285-
databaseId?: string;
286285
namespace?: string;
287286
path: PathType[];
288287
}
@@ -365,7 +364,6 @@ export namespace entity {
365364
*/
366365
export class Key {
367366
namespace?: string;
368-
databaseId?: string;
369367
id?: string;
370368
name?: string;
371369
kind: string;
@@ -378,7 +376,6 @@ export namespace entity {
378376
* @type {string}
379377
*/
380378
this.namespace = options.namespace;
381-
this.databaseId = options.databaseId;
382379

383380
options.path = [].slice.call(options.path);
384381

@@ -1115,20 +1112,10 @@ export namespace entity {
11151112
path: [],
11161113
};
11171114

1118-
if (key.namespace || key.databaseId) {
1119-
keyProto.partitionId = Object.assign(
1120-
{},
1121-
key.namespace
1122-
? {
1123-
namespaceId: key.namespace,
1124-
}
1125-
: null,
1126-
key.databaseId
1127-
? {
1128-
databaseId: key.databaseId,
1129-
}
1130-
: null
1131-
);
1115+
if (key.namespace) {
1116+
keyProto.partitionId = {
1117+
namespaceId: key.namespace,
1118+
};
11321119
}
11331120

11341121
let numKeysWalked = 0;

0 commit comments

Comments
 (0)