Merge pull request #563 from monochrome-music/copilot/fix-artist-page-fallback

Fix artist page: correct ServerAPI fallback URL and picture field
This commit is contained in:
binimum 2026-04-17 09:25:36 +01:00 committed by GitHub
commit 60635b3513
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 3 additions and 8 deletions

View file

@ -116,13 +116,8 @@ class ServerAPI {
}
async getArtistMetadata(id) {
try {
const response = await this.fetchWithRetry(`/artist/${id}`);
return await response.json();
} catch {
const response = await this.fetchWithRetry(`/artist?id=${id}`);
return await response.json();
}
const response = await this.fetchWithRetry(`/artist/?id=${id}`);
return await response.json();
}
getArtistPictureUrl(id, size = '750') {

View file

@ -1041,7 +1041,7 @@ export class LosslessAPI {
const artist = {
...this.prepareArtist(rawArtist),
picture: rawArtist.picture || primaryData.cover || null,
picture: rawArtist.picture || null,
name: rawArtist.name || 'Unknown Artist',
};