This repository has been archived on 2022-08-19. You can view files and clone it, but cannot push or open issues or pull requests.
hydrogen-web/src/matrix/storage/idb/stores/RoomStateStore.js
Bruno Windels 001dbefbcf stop using default exports
because it becomes hard to remember where you used them and where not
2020-04-20 21:26:39 +02:00

20 lines
365 B
JavaScript

export class RoomStateStore {
constructor(idbStore) {
this._roomStateStore = idbStore;
}
async getEvents(type) {
}
async getEventsForKey(type, stateKey) {
}
async setStateEvent(roomId, event) {
const key = `${roomId}|${event.type}|${event.state_key}`;
const entry = {roomId, event, key};
return this._roomStateStore.put(entry);
}
}