Skip to content

Commit 362fcd4

Browse files
committed
fix: debug logs
1 parent 8ac20f8 commit 362fcd4

File tree

1 file changed

+3
-4
lines changed

1 file changed

+3
-4
lines changed

examples/SampleApp/src/hooks/useChatClient.ts

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ import { USER_TOKENS, USERS } from '../ChatUsers';
77
import AsyncStore from '../utils/AsyncStore';
88

99
import type { LoginConfig, StreamChatGenerics } from '../types';
10-
import { Alert, PermissionsAndroid, Platform } from 'react-native';
10+
import { PermissionsAndroid, Platform } from 'react-native';
1111

1212
const messaging = getMessaging();
1313

@@ -21,7 +21,6 @@ const requestNotificationPermission = async () => {
2121
};
2222

2323
messaging.setBackgroundMessageHandler(async (remoteMessage) => {
24-
Alert.alert(`NEW REMOTE MESSAGE: ${remoteMessage.messageId}`);
2524
const messageId = remoteMessage.data?.id as string;
2625
if (!messageId) {
2726
return;
@@ -64,7 +63,7 @@ messaging.setBackgroundMessageHandler(async (remoteMessage) => {
6463
id: 'default',
6564
},
6665
},
67-
title: 'Background: New message from ' + message.message.user.name,
66+
title: 'New message from ' + message.message.user.name,
6867
body: message.message.text,
6968
data,
7069
});
@@ -162,7 +161,7 @@ export const useChatClient = () => {
162161
},
163162
body: message.message.text,
164163
data,
165-
title: 'Foreground: New message from ' + message.message.user.name,
164+
title: 'New message from ' + message.message.user.name,
166165
});
167166
}
168167
});

0 commit comments

Comments
 (0)