Correção de erro 500 em mensagens (UUID), criação de tabela messages e tratamento defensivo no front-end para evitar crashes

This commit is contained in:
2026-04-03 16:12:53 +00:00
parent 4841dde110
commit 9a34502bd7
6 changed files with 26 additions and 9 deletions

View File

@@ -83,7 +83,7 @@ export const NotificationProvider: React.FC<{ children: React.ReactNode }> = ({
}
}, [isSignedIn, fetchNotifications]);
const unreadCount = notifications.filter(n => !n.isRead).length;
const unreadCount = (notifications || []).filter(n => !n.isRead).length;
return (
<NotificationContext.Provider value={{