From 6418d613e15e5a28ee7f05901cf4cf6e0c0415f9 Mon Sep 17 00:00:00 2001 From: devthejo Date: Tue, 1 Jul 2025 22:39:45 +0200 Subject: [PATCH] chore: wip --- src/location/trackLocation.js | 23 ++--------------------- 1 file changed, 2 insertions(+), 21 deletions(-) diff --git a/src/location/trackLocation.js b/src/location/trackLocation.js index 9c34a83..e0c59e3 100644 --- a/src/location/trackLocation.js +++ b/src/location/trackLocation.js @@ -105,25 +105,6 @@ export default async function trackLocation() { }, ); - // Verify the current configuration - try { - const currentConfig = await BackgroundGeolocation.getConfig(); - locationLogger.debug("Current background geolocation config", { - hasHeaders: !!currentConfig.headers, - headerKeys: currentConfig.headers - ? Object.keys(currentConfig.headers) - : [], - authHeader: currentConfig.headers?.Authorization - ? currentConfig.headers.Authorization.substring(0, 15) + "..." - : "Not set", - url: currentConfig.url, - }); - } catch (error) { - locationLogger.error("Failed to get background geolocation config", { - error: error.message, - }); - } - const state = await BackgroundGeolocation.getState(); try { const decodedToken = jwtDecode(userToken); @@ -235,10 +216,10 @@ export default async function trackLocation() { }); switch (statusCode) { - case 410: case 401: + case 410: // Auth token expired, logout - locationLogger.info("Auth token expired (410), logging out"); + locationLogger.info("Auth token expired, logging out"); Sentry.addBreadcrumb({ message: "Auth token expired - logging out", category: "geolocation-auth",