From dc82203e9b0f88e5da386d17e13e7e2b46db49cf Mon Sep 17 00:00:00 2001 From: syuilo Date: Mon, 8 Apr 2019 00:24:01 +0900 Subject: [PATCH] Fix bug --- src/models/repositories/user.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/models/repositories/user.ts b/src/models/repositories/user.ts index 7c4cc545cf..acdf6c8f18 100644 --- a/src/models/repositories/user.ts +++ b/src/models/repositories/user.ts @@ -140,7 +140,7 @@ export class UserRepository extends Repository { }).then(count => count > 0), hasUnreadNotification: Notifications.count({ where: { - userId: user.id, + notifieeId: user.id, isRead: false }, take: 1