Skip to content

Commit

Permalink
LRCLIB: Safer code to prevent throwing exception to fetchLyrics() (ca…
Browse files Browse the repository at this point in the history
…using us to not run the isEmptyPostLoad check, not updating fullscreen no lyric songs)
  • Loading branch information
aviwad committed Nov 19, 2024
1 parent ebaf97e commit 42e75e6
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion SpotifyLyricsInMenubar/viewModel.swift
Original file line number Diff line number Diff line change
Expand Up @@ -392,7 +392,7 @@ import NaturalLanguage
let urlResponseAndData = try await fakeSpotifyUserAgentSession.data(for: request)
if urlResponseAndData.0.isEmpty {
print("F")
return try await fetchLRCLIBNetworkLyrics( trackName: trackName, spotifyOrAppleMusic: spotifyOrAppleMusic, trackID: trackID)
return (try? await fetchLRCLIBNetworkLyrics( trackName: trackName, spotifyOrAppleMusic: spotifyOrAppleMusic, trackID: trackID)) ?? []
// return []
}
print(String(decoding: urlResponseAndData.0, as: UTF8.self))
Expand Down

0 comments on commit 42e75e6

Please sign in to comment.