MCPcopy Create free account
hub / github.com/Fibi66/FeiControl / loadNotifications

Function loadNotifications

src/app/api/notifications/route.ts:24–31  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

22}
23
24async function loadNotifications(): Promise<Notification[]> {
25 try {
26 const data = await fs.readFile(DATA_PATH, 'utf-8');
27 return JSON.parse(data);
28 } catch {
29 return [];
30 }
31}
32
33async function saveNotifications(notifications: Notification[]): Promise<void> {
34 const dir = path.dirname(DATA_PATH);

Callers 4

GETFunction · 0.85
POSTFunction · 0.85
PATCHFunction · 0.85
DELETEFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected