Merge branch 'poljar/shutdown' into develop
This commit is contained in:
commit
997a179e69
2 changed files with 4 additions and 3 deletions
|
@ -564,7 +564,8 @@ export default class EventIndex extends EventEmitter {
|
||||||
const indexManager = PlatformPeg.get().getEventIndexingManager();
|
const indexManager = PlatformPeg.get().getEventIndexingManager();
|
||||||
this.removeListeners();
|
this.removeListeners();
|
||||||
this.stopCrawler();
|
this.stopCrawler();
|
||||||
return indexManager.closeEventIndex();
|
await indexManager.closeEventIndex();
|
||||||
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
|
@ -135,7 +135,7 @@ class EventIndexPeg {
|
||||||
*/
|
*/
|
||||||
async unset() {
|
async unset() {
|
||||||
if (this.index === null) return;
|
if (this.index === null) return;
|
||||||
this.index.close();
|
await this.index.close();
|
||||||
this.index = null;
|
this.index = null;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -151,7 +151,7 @@ class EventIndexPeg {
|
||||||
const indexManager = PlatformPeg.get().getEventIndexingManager();
|
const indexManager = PlatformPeg.get().getEventIndexingManager();
|
||||||
|
|
||||||
if (indexManager !== null) {
|
if (indexManager !== null) {
|
||||||
this.unset();
|
await this.unset();
|
||||||
console.log("EventIndex: Deleting event index.");
|
console.log("EventIndex: Deleting event index.");
|
||||||
await indexManager.deleteEventIndex();
|
await indexManager.deleteEventIndex();
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue