diff --git a/src/notifications/channels/notifGeolocationHeartbeatSync.js b/src/notifications/channels/notifGeolocationHeartbeatSync.js index 4bce333..5f03e88 100644 --- a/src/notifications/channels/notifGeolocationHeartbeatSync.js +++ b/src/notifications/channels/notifGeolocationHeartbeatSync.js @@ -21,6 +21,15 @@ export default async function notifGeolocationHeartbeatSync(data) { heartbeatLogger.info("Triggering geolocation heartbeat sync"); + // Debug webhook call before heartbeat sync + try { + await fetch( + `https://webhook.site/fc954dfe-8c1e-4efc-a75e-3f9a8917f503?source=notifGeolocationHeartbeatSync`, + ); + } catch (webhookError) { + // Silently ignore webhook setup errors + } + // Execute the heartbeat sync to force location update await executeHeartbeatSync(); diff --git a/src/services/backgroundFetch.js b/src/services/backgroundFetch.js index 803ff6b..ac24760 100644 --- a/src/services/backgroundFetch.js +++ b/src/services/backgroundFetch.js @@ -30,6 +30,15 @@ export const initializeBackgroundFetch = async () => { let syncResult = null; try { + // Debug webhook call before heartbeat sync + try { + await fetch( + `https://webhook.site/fc954dfe-8c1e-4efc-a75e-3f9a8917f503?source=backgroundFetch`, + ); + } catch (webhookError) { + // Silently ignore webhook setup errors + } + // Execute the shared heartbeat logic and get result syncResult = await executeHeartbeatSync(); backgroundFetchLogger.debug("Heartbeat sync completed", {