fix incorrect matcher for addOrUpdateEta

This commit is contained in:
2024-12-22 14:33:13 -08:00
parent c476ea504f
commit 702b14482f

View File

@@ -127,7 +127,7 @@ export class UnoptimizedInMemoryRepository implements Repository {
}
public async addOrUpdateEta(eta: IEta): Promise<void> {
const index = this.etas.findIndex((e) => e.id === eta.id);
const index = this.etas.findIndex((e) => e.stopId === eta.stopId && e.shuttleId === eta.shuttleId);
if (index !== -1) {
this.etas[index] = eta;
} else {