Skip to content

Commit 35546a1

Browse files
More build fixes
1 parent 2a03cae commit 35546a1

File tree

2 files changed

+3
-12
lines changed

2 files changed

+3
-12
lines changed

packages/firestore/src/core/component_provider.ts

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -345,17 +345,13 @@ export class OnlineComponentProvider {
345345
await this.remoteStore.applyPrimaryState(this.syncEngine.isPrimaryClient);
346346
}
347347

348-
protected loadConnection(cfg: ComponentConfiguration): Connection {
349-
return newConnection(cfg.databaseInfo);
350-
}
351-
352348
createEventManager(cfg: ComponentConfiguration): EventManager {
353349
return new EventManager(this.syncEngine);
354350
}
355351

356352
createDatastore(cfg: ComponentConfiguration): Datastore {
357353
const serializer = newSerializer(cfg.databaseInfo.databaseId);
358-
const connection = this.loadConnection(cfg);
354+
const connection = newConnection(cfg.databaseInfo);
359355
return newDatastore(cfg.credentials, connection, serializer);
360356
}
361357

packages/firestore/test/unit/specs/spec_test_components.ts

Lines changed: 2 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -122,18 +122,13 @@ function failTransactionIfNeeded(
122122

123123
export class MockOnlineComponentProvider extends OnlineComponentProvider {
124124
connection!: MockConnection;
125-
126-
async loadConnection(cfg: ComponentConfiguration): Promise<Connection> {
127-
this.connection = new MockConnection(cfg.asyncQueue);
128-
return this.connection;
129-
}
130-
125+
131126
createDatastore(cfg: ComponentConfiguration): Datastore {
132127
const serializer = new JsonProtoSerializer(
133128
cfg.databaseInfo.databaseId,
134129
/* useProto3Json= */ true
135130
);
136-
return newDatastore(cfg.credentials, serializer);
131+
return newDatastore(cfg.credentials, new MockConnection(cfg.asyncQueue), serializer);
137132
}
138133
}
139134

0 commit comments

Comments
 (0)