[Store] Add missing comma

This commit is contained in:
Marcel 2019-07-18 20:03:45 +02:00
parent 0fb76874e6
commit 14b89263b7
No known key found for this signature in database
GPG key ID: B5E03B5BF119B26C

View file

@ -624,16 +624,19 @@ class Store {
}
Future forgetNotification(String roomID) async {
await db.rawDelete("DELETE FROM NotificationsCache WHERE chat_id=?", [roomID]);
await db
.rawDelete("DELETE FROM NotificationsCache WHERE chat_id=?", [roomID]);
return;
}
Future addNotification(String roomID, String event_id, int uniqueID) async {
await db.rawInsert("INSERT INTO NotificationsCache VALUES (?, ?,?)", [uniqueID, roomID, event_id]);
await db.rawInsert("INSERT INTO NotificationsCache VALUES (?, ?,?)",
[uniqueID, roomID, event_id]);
return;
}
Future<List<Map<String, dynamic>>> getNotificationByRoom(String room_id) async {
Future<List<Map<String, dynamic>>> getNotificationByRoom(
String room_id) async {
List<Map<String, dynamic>> res = await db.rawQuery(
"SELECT * FROM NotificationsCache WHERE chat_id=?", [room_id]);
if (res.length == 0) return null;
@ -717,8 +720,9 @@ class Store {
'UNIQUE(chat_id, matrix_id))';
/// The database scheme for the NotificationsCache class.
static final String NotificationsCacheScheme = 'CREATE TABLE IF NOT EXISTS NotificationsCache(' +
'id int PRIMARY KEY'
static final String NotificationsCacheScheme =
'CREATE TABLE IF NOT EXISTS NotificationsCache(' +
'id int PRIMARY KEY, ' +
'chat_id TEXT, ' + // The chat id
'event_id TEXT, ' + // The matrix id of the Event
'UNIQUE(event_id))';