Merge branch 'store-fix-query' into 'master'

[Store] Fix event query

See merge request famedly/famedlysdk!70
This commit is contained in:
Marcel 2019-09-03 11:42:13 +00:00
commit c2bfc7a749
1 changed files with 1 additions and 1 deletions

View File

@ -398,7 +398,7 @@ class Store {
/// Searches for the event in the store.
Future<Event> getEventById(String eventID, Room room) async {
List<Map<String, dynamic>> res = await db.rawQuery(
"SELECT * FROM Events WHERE id=? AND room_id=?", [eventID, room.id]);
"SELECT * FROM Events WHERE event_id=? AND room_id=?", [eventID, room.id]);
if (res.length == 0) return null;
return Event.fromJson(res[0], room);
}