You've already forked matrix-react-sdk
mirror of
https://github.com/matrix-org/matrix-react-sdk.git
synced 2025-11-11 20:22:36 +03:00
EventIndex: Properly await the index closing.
This commit is contained in:
@@ -135,7 +135,7 @@ class EventIndexPeg {
|
||||
*/
|
||||
async unset() {
|
||||
if (this.index === null) return;
|
||||
this.index.close();
|
||||
await this.index.close();
|
||||
this.index = null;
|
||||
}
|
||||
|
||||
@@ -151,7 +151,7 @@ class EventIndexPeg {
|
||||
const indexManager = PlatformPeg.get().getEventIndexingManager();
|
||||
|
||||
if (indexManager !== null) {
|
||||
this.unset();
|
||||
await this.unset();
|
||||
console.log("EventIndex: Deleting event index.");
|
||||
await indexManager.deleteEventIndex();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user