@@ -166,7 +166,7 @@ class PushNotificationService {
166166 } ;
167167
168168 // Show the notification modal using the store
169- usePushNotificationModalStore . getState ( ) . showNotificationModal ( notificationData ) ;
169+ await usePushNotificationModalStore . getState ( ) . showNotificationModal ( notificationData ) ;
170170 }
171171 } ;
172172
@@ -201,7 +201,7 @@ class PushNotificationService {
201201 context : { eventCode, title } ,
202202 } ) ;
203203
204- usePushNotificationModalStore . getState ( ) . showNotificationModal ( notificationData ) ;
204+ await usePushNotificationModalStore . getState ( ) . showNotificationModal ( notificationData ) ;
205205 }
206206 }
207207 } ) ;
@@ -231,7 +231,7 @@ class PushNotificationService {
231231 context : { eventCode, title } ,
232232 } ) ;
233233
234- usePushNotificationModalStore . getState ( ) . showNotificationModal ( notificationData ) ;
234+ await usePushNotificationModalStore . getState ( ) . showNotificationModal ( notificationData ) ;
235235 }
236236 }
237237 } ) ;
@@ -294,7 +294,7 @@ class PushNotificationService {
294294
295295 // Handle notification tap
296296 // Use a small delay to ensure the app is fully initialized and the store is ready
297- setTimeout ( ( ) => {
297+ setTimeout ( async ( ) => {
298298 if ( eventCode && typeof eventCode === 'string' ) {
299299 const notificationData = {
300300 eventCode : eventCode ,
@@ -309,7 +309,7 @@ class PushNotificationService {
309309 } ) ;
310310
311311 // Show the notification modal using the store
312- usePushNotificationModalStore . getState ( ) . showNotificationModal ( notificationData ) ;
312+ await usePushNotificationModalStore . getState ( ) . showNotificationModal ( notificationData ) ;
313313 }
314314 } , 300 ) ;
315315 } ) ;
@@ -336,7 +336,7 @@ class PushNotificationService {
336336
337337 // Handle the initial notification
338338 // Use a delay to ensure the app is fully loaded and the store is ready
339- setTimeout ( ( ) => {
339+ setTimeout ( async ( ) => {
340340 if ( eventCode && typeof eventCode === 'string' ) {
341341 const notificationData = {
342342 eventCode : eventCode ,
@@ -351,7 +351,7 @@ class PushNotificationService {
351351 } ) ;
352352
353353 // Show the notification modal using the store
354- usePushNotificationModalStore . getState ( ) . showNotificationModal ( notificationData ) ;
354+ await usePushNotificationModalStore . getState ( ) . showNotificationModal ( notificationData ) ;
355355 }
356356 } , 500 ) ;
357357 }
0 commit comments