From eabd303c8e9fb06d1f14e80a84bfc4d0439dcbd2 Mon Sep 17 00:00:00 2001 From: Bruno Windels Date: Fri, 28 Jan 2022 15:14:58 +0100 Subject: [PATCH] count on the index if we're using one, don't always take the store --- src/matrix/storage/idb/Store.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/matrix/storage/idb/Store.ts b/src/matrix/storage/idb/Store.ts index 20e6f79a..c9df33b2 100644 --- a/src/matrix/storage/idb/Store.ts +++ b/src/matrix/storage/idb/Store.ts @@ -120,7 +120,7 @@ export class QueryTargetWrapper { count(keyRange?: IDBKeyRange): IDBRequest { try { - return this._qtStore.count(keyRange); + return this._qt.count(keyRange); } catch(err) { throw new IDBRequestAttemptError("count", this._qt, err, [keyRange]); }