From d5a52c32d651ee516caf5a77ffeae0baf47a12f5 Mon Sep 17 00:00:00 2001 From: Bruno Windels Date: Tue, 29 Sep 2020 11:51:14 +0200 Subject: [PATCH] these don't return a promise anymore --- src/matrix/storage/idb/stores/PendingEventStore.js | 4 ++-- src/matrix/storage/idb/stores/SessionStore.js | 4 ++-- src/matrix/storage/idb/stores/TimelineEventStore.js | 4 ++-- src/matrix/storage/idb/stores/TimelineFragmentStore.js | 4 ++-- 4 files changed, 8 insertions(+), 8 deletions(-) diff --git a/src/matrix/storage/idb/stores/PendingEventStore.js b/src/matrix/storage/idb/stores/PendingEventStore.js index 00898311..59b79a05 100644 --- a/src/matrix/storage/idb/stores/PendingEventStore.js +++ b/src/matrix/storage/idb/stores/PendingEventStore.js @@ -58,11 +58,11 @@ export class PendingEventStore { add(pendingEvent) { pendingEvent.key = encodeKey(pendingEvent.roomId, pendingEvent.queueIndex); - return this._eventStore.add(pendingEvent); + this._eventStore.add(pendingEvent); } update(pendingEvent) { - return this._eventStore.put(pendingEvent); + this._eventStore.put(pendingEvent); } getAll() { diff --git a/src/matrix/storage/idb/stores/SessionStore.js b/src/matrix/storage/idb/stores/SessionStore.js index c6486651..3be8e875 100644 --- a/src/matrix/storage/idb/stores/SessionStore.js +++ b/src/matrix/storage/idb/stores/SessionStore.js @@ -27,11 +27,11 @@ export class SessionStore { } set(key, value) { - return this._sessionStore.put({key, value}); + this._sessionStore.put({key, value}); } add(key, value) { - return this._sessionStore.add({key, value}); + this._sessionStore.add({key, value}); } remove(key) { diff --git a/src/matrix/storage/idb/stores/TimelineEventStore.js b/src/matrix/storage/idb/stores/TimelineEventStore.js index 9a5fddfc..b7712337 100644 --- a/src/matrix/storage/idb/stores/TimelineEventStore.js +++ b/src/matrix/storage/idb/stores/TimelineEventStore.js @@ -238,7 +238,7 @@ export class TimelineEventStore { entry.key = encodeKey(entry.roomId, entry.fragmentId, entry.eventIndex); entry.eventIdKey = encodeEventIdKey(entry.roomId, entry.event.event_id); // TODO: map error? or in idb/store? - return this._timelineStore.add(entry); + this._timelineStore.add(entry); } /** Updates the entry into the store with the given [roomId, eventKey] combination. @@ -247,7 +247,7 @@ export class TimelineEventStore { * @return {Promise<>} a promise resolving to undefined if the operation was successful, or a StorageError if not. */ update(entry) { - return this._timelineStore.put(entry); + this._timelineStore.put(entry); } get(roomId, eventKey) { diff --git a/src/matrix/storage/idb/stores/TimelineFragmentStore.js b/src/matrix/storage/idb/stores/TimelineFragmentStore.js index 2a28c7bc..849e5204 100644 --- a/src/matrix/storage/idb/stores/TimelineFragmentStore.js +++ b/src/matrix/storage/idb/stores/TimelineFragmentStore.js @@ -62,11 +62,11 @@ export class TimelineFragmentStore { // like give them meaning depending on range. not for now probably ... add(fragment) { fragment.key = encodeKey(fragment.roomId, fragment.id); - return this._store.add(fragment); + this._store.add(fragment); } update(fragment) { - return this._store.put(fragment); + this._store.put(fragment); } get(roomId, fragmentId) {