use env var for MS base url
Deploy / Deploy (push) Successful in 4m7s Details

This commit is contained in:
Rik Berkelder 2025-01-15 22:10:23 +01:00
parent a48454f96b
commit 12b31dfc03
1 changed files with 2 additions and 1 deletions

View File

@ -10,6 +10,7 @@ import { fileURLToPath } from 'url';
const __filename = fileURLToPath(import.meta.url);
const __dirname = path.dirname(__filename);
const mdBaseUrl = process.env.MD_BASE_URL;
const apiId = parseInt(process.env.API_ID);
const apiHash = process.env.API_HASH;
const songPrefix = process.env.SONG_PREFIX || "";
@ -27,7 +28,7 @@ try {
}
async function getCurrentSong() {
return fetch('https://multi-scrobbler.riksolo.com/api/status').then((data) => {
return fetch(mdBaseUrl + '/api/status').then((data) => {
return data.json();
}).then(data => {
const players = [];