From 02c744ceb80ffbe56bee4cd98b0eaf435814272f Mon Sep 17 00:00:00 2001
From: dzak27567 <fadhlurohmandzaki@gmail.com>
Date: Thu, 27 Mar 2025 12:49:39 +0700
Subject: [PATCH] Implement add function in Subscriber repository.

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

diff --git a/src/repository/notification.rs b/src/repository/notification.rs
index 5071dde..907f2cb 100644
--- a/src/repository/notification.rs
+++ b/src/repository/notification.rs
@@ -12,4 +12,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