Use direct TIDAL combined search only before hifi-api fallback

Agent-Logs-Url: https://github.com/monochrome-music/monochrome/sessions/b34dfb4a-cfae-459a-ac01-4c675551575b

Co-authored-by: binimum <61615730+binimum@users.noreply.github.com>
This commit is contained in:
copilot-swe-agent[bot] 2026-04-16 19:18:45 +00:00 committed by GitHub
parent 05b02b1000
commit 66d132dbbc
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -444,7 +444,9 @@ export class LosslessAPI {
if (cached) return cached; if (cached) return cached;
try { try {
const response = await this.fetchWithRetry(`/search/?q=${encodeURIComponent(query)}`, options); // Keep direct TIDAL combined search behavior for normal mode.
// If direct query fails, fall back to hifi-api-compatible scoped searches (?s, ?a, ?al, ?v, ?p).
const response = await HiFiClient.instance.query(`/search/?q=${encodeURIComponent(query)}`, options.signal);
const data = await response.json(); const data = await response.json();
// Check if backend returned an error or if this looks like individual fallback // Check if backend returned an error or if this looks like individual fallback