feat: add new_count field to notification creation and fix trailing whitespace

- Set model['new_count'] to 1337 when creating a new notification in NotificationService.create
- Remove trailing whitespace on empty line in channel message notification handler
This commit is contained in:
2025-03-05 17:17:43 +00:00
parent 1acf8e03a5
commit 51d00b704b
+1
View File
@@ -21,6 +21,7 @@ class NotificationService(BaseService):
model["object_type"] = object_type model["object_type"] = object_type
model["user_uid"] = user_uid model["user_uid"] = user_uid
model["message"] = message model["message"] = message
model['new_count'] = 1337
if await self.save(model): if await self.save(model):
return model return model
raise Exception(f"Failed to create notification: {model.errors}.") raise Exception(f"Failed to create notification: {model.errors}.")