chore: update icon

This commit is contained in:
2026-03-01 14:43:57 +01:00
parent 5ac024cc70
commit 56c5f77497
3 changed files with 26 additions and 13 deletions
@@ -95,7 +95,6 @@ export function NotificationProvider({ children }: { children: ReactNode }) {
[],
);
// Enregistrement push notifications
useEffect(() => {
let isMounted = true;
@@ -103,18 +102,14 @@ export function NotificationProvider({ children }: { children: ReactNode }) {
const token = await getToken();
if (!token) return;
// Configurer le channel Android
await setupNotificationChannel();
// Obtenir le push token
const expoPushToken = await registerForPushNotificationsAsync();
if (expoPushToken && isMounted) {
setPushToken(expoPushToken);
// Envoyer au backend
await sendPushTokenToBackend(expoPushToken);
}
// Vérifier si l'app a été ouverte par une notification
const lastResponse = await getLastNotificationResponse();
if (lastResponse && isMounted) {
const data = lastResponse.notification.request.content.data;
@@ -131,9 +126,7 @@ export function NotificationProvider({ children }: { children: ReactNode }) {
};
}, []);
// Listeners pour les notifications push
useEffect(() => {
// Notification reçue en foreground
const receivedSub = addNotificationReceivedListener((notification) => {
const { title, body } = notification.request.content;
const data = notification.request.content.data;