1
0
mirror of https://gitlab.com/comunic/comunicapiv2 synced 2024-11-24 22:39:21 +00:00

Can delete a specific notification

This commit is contained in:
Pierre HUBERT 2020-03-25 08:24:10 +01:00
parent c67112d926
commit 3bf3f18710

View File

@ -245,7 +245,9 @@ export class NotificationsHelper {
public static async Delete(n: Notif) {
// Delete a specific notification
if(n.hasId)
throw new Error("Please implement notification deletion with known ID!");
await DatabaseHelper.DeleteRows(NOTIFICATIONS_TABLE, {
id: n.id
})
// Delete wider range of notifications
else