Fix store
This commit is contained in:
parent
519f32c8d1
commit
41577ada6d
|
@ -15,7 +15,7 @@ class Store extends StoreAPI {
|
||||||
final FlutterSecureStorage secureStorage;
|
final FlutterSecureStorage secureStorage;
|
||||||
|
|
||||||
Store(this.client)
|
Store(this.client)
|
||||||
: storage = !kIsWeb ? null : LocalStorage('LocalStorage'),
|
: storage = LocalStorage('LocalStorage'),
|
||||||
secureStorage = kIsWeb ? null : FlutterSecureStorage() {
|
secureStorage = kIsWeb ? null : FlutterSecureStorage() {
|
||||||
_init();
|
_init();
|
||||||
}
|
}
|
||||||
|
@ -351,8 +351,8 @@ class ExtendedStore extends Store implements ExtendedStoreAPI {
|
||||||
|
|
||||||
if (type == "history") return null;
|
if (type == "history") return null;
|
||||||
|
|
||||||
if (type != "account_data" && eventUpdate.content["event_id"] != null ||
|
if (type != "account_data" &&
|
||||||
eventUpdate.content["state_key"] != null) {
|
eventUpdate.content.containsKey("state_key")) {
|
||||||
final String now = DateTime.now().millisecondsSinceEpoch.toString();
|
final String now = DateTime.now().millisecondsSinceEpoch.toString();
|
||||||
txn.rawInsert(
|
txn.rawInsert(
|
||||||
"INSERT OR REPLACE INTO RoomStates VALUES(?, ?, ?, ?, ?, ?, ?, ?, ?)",
|
"INSERT OR REPLACE INTO RoomStates VALUES(?, ?, ?, ?, ?, ?, ?, ?, ?)",
|
||||||
|
|
Loading…
Reference in a new issue