clean up
This commit is contained in:
@@ -54,6 +54,7 @@ build/
|
|||||||
|
|
||||||
# Project specific files
|
# Project specific files
|
||||||
dev-start.sh
|
dev-start.sh
|
||||||
|
generate-config.sh
|
||||||
labels.example
|
labels.example
|
||||||
virt-game-timer.service
|
virt-game-timer.service
|
||||||
package.json
|
package.json
|
||||||
|
|||||||
@@ -23,10 +23,6 @@ async function initialize() {
|
|||||||
// Use the ensureEnvLoaded function from config.js to make sure environment variables are loaded
|
// Use the ensureEnvLoaded function from config.js to make sure environment variables are loaded
|
||||||
await config.ensureEnvLoaded();
|
await config.ensureEnvLoaded();
|
||||||
console.log("Environment variables loaded and verified");
|
console.log("Environment variables loaded and verified");
|
||||||
|
|
||||||
// Log the loaded environment variables for debugging
|
|
||||||
console.log("BACKEND_URL:", config.getBackendUrl());
|
|
||||||
console.log("PUBLIC_VAPID_KEY:", config.getPublicVapidKey());
|
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
console.warn("Failed to load environment variables, using defaults:", error);
|
console.warn("Failed to load environment variables, using defaults:", error);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -154,8 +154,6 @@ async function sendSubscriptionToServer(subscription, buttonId) {
|
|||||||
|
|
||||||
try {
|
try {
|
||||||
// Add support for handling CORS preflight with credentials
|
// Add support for handling CORS preflight with credentials
|
||||||
console.log("BACKEND_URL Key: " + getBackendUrl());
|
|
||||||
console.log("FLIC_BUTTON_ID Key: " + FLIC_BUTTON_ID);
|
|
||||||
const response = await fetch(`${getBackendUrl()}/subscribe`, {
|
const response = await fetch(`${getBackendUrl()}/subscribe`, {
|
||||||
method: 'POST',
|
method: 'POST',
|
||||||
body: JSON.stringify({ button_id: buttonId, subscription: subscription }),
|
body: JSON.stringify({ button_id: buttonId, subscription: subscription }),
|
||||||
|
|||||||
Reference in New Issue
Block a user