mirror of
https://github.com/element-hq/element-web
synced 2024-11-27 19:56:47 +03:00
EventIndexing: Don't scope the event index per user.
This commit is contained in:
parent
9b32ec10b4
commit
28d2e658a4
3 changed files with 4 additions and 8 deletions
|
@ -91,13 +91,10 @@ export default class BaseEventIndexManager {
|
|||
/**
|
||||
* Initialize the event index for the given user.
|
||||
*
|
||||
* @param {string} userId The unique identifier of the logged in user that
|
||||
* owns the index.
|
||||
*
|
||||
* @return {Promise} A promise that will resolve when the event index is
|
||||
* initialized.
|
||||
*/
|
||||
async initEventIndex(userId: string): Promise<> {
|
||||
async initEventIndex(): Promise<> {
|
||||
throw new Error("Unimplemented");
|
||||
}
|
||||
|
||||
|
|
|
@ -56,10 +56,9 @@ class EventIndexPeg {
|
|||
}
|
||||
|
||||
const index = new EventIndex();
|
||||
const userId = MatrixClientPeg.get().getUserId();
|
||||
|
||||
try {
|
||||
await index.init(userId);
|
||||
await index.init();
|
||||
} catch (e) {
|
||||
console.log("EventIndex: Error initializing the event index", e);
|
||||
}
|
||||
|
|
|
@ -33,10 +33,10 @@ export default class EventIndexer {
|
|||
this.liveEventsForIndex = new Set();
|
||||
}
|
||||
|
||||
async init(userId) {
|
||||
async init() {
|
||||
const indexManager = PlatformPeg.get().getEventIndexingManager();
|
||||
if (indexManager === null) return false;
|
||||
indexManager.initEventIndex(userId);
|
||||
indexManager.initEventIndex();
|
||||
return true;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue