From b5cd39cc178ada2f739b06e688711a4f61f36483 Mon Sep 17 00:00:00 2001
From: Scallss <pascalhafidz2005@gmail.com>
Date: Fri, 28 Mar 2025 17:03:07 +0700
Subject: [PATCH] Implement add function in Subscriber repository.

---
 src/repository/notification.rs | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)

diff --git a/src/repository/notification.rs b/src/repository/notification.rs
index 44f2bd4..0896000 100644
--- a/src/repository/notification.rs
+++ b/src/repository/notification.rs
@@ -11,5 +11,9 @@ lazy_static! {
 pub struct NotificationRepository;
 
 impl NotificationRepository {
-
+    pub fn add(notification: Notification) -> Notification{
+        NOTIFICATIONS.write().unwrap()
+            .push(notification.clone());
+        return notification;
+    }
 }
\ No newline at end of file
-- 
GitLab