File tree Expand file tree Collapse file tree 2 files changed +1
-12
lines changed
components/push-notification Expand file tree Collapse file tree 2 files changed +1
-12
lines changed Original file line number Diff line number Diff line change @@ -7,14 +7,10 @@ import { usePushNotifications } from '@/services/push-notification';
77import { useCoreStore } from '@/stores/app/core-store' ;
88
99export function PushNotificationStatus ( ) {
10- const { pushToken, sendTestNotification } = usePushNotifications ( ) ;
10+ const { pushToken } = usePushNotifications ( ) ;
1111 const activeUnitId = useCoreStore ( ( state ) => state . activeUnitId ) ;
1212 const activeUnit = useCoreStore ( ( state ) => state . activeUnit ) ;
1313
14- const handleTestNotification = ( ) => {
15- sendTestNotification ( ) ;
16- } ;
17-
1814 return (
1915 < Box className = "my-2 rounded-md border border-gray-300 p-4" >
2016 < Text className = "mb-2 font-bold" > Push Notification Status</ Text >
@@ -28,12 +24,6 @@ export function PushNotificationStatus() {
2824 < Text className = "text-sm text-gray-700" > Push Token: { pushToken ? `${ pushToken . substring ( 0 , 20 ) } ...` : 'Not registered' } </ Text >
2925 < Text className = { `text-sm ${ pushToken ? 'text-green-700' : 'text-red-700' } ` } > Status: { pushToken ? 'Registered' : 'Not Registered' } </ Text >
3026 </ Box >
31-
32- < Box className = "mt-4" >
33- < Button className = "bg-blue-600 text-white" onPress = { handleTestNotification } disabled = { ! pushToken } >
34- Send Test Notification
35- </ Button >
36- </ Box >
3727 </ Box >
3828 ) ;
3929}
Original file line number Diff line number Diff line change @@ -294,6 +294,5 @@ export const usePushNotifications = () => {
294294
295295 return {
296296 pushToken : pushNotificationService . getPushToken ( ) ,
297- sendTestNotification : ( ) => pushNotificationService . sendTestNotification ( ) ,
298297 } ;
299298} ;
You can’t perform that action at this time.
0 commit comments