mirror of
https://github.com/SoPat712/allstarr.git
synced 2026-10-08 14:05:02 -04:00
fix(squidwtf): resolve Song nullable warning in metadata fallback
This commit is contained in:
2 files changed
+6
-6
No files matched your search
@@ -9,5 +9,5 @@ public static class AppVersion
|
||||
/// <summary>
|
||||
/// Current application version.
|
||||
/// </summary>
|
||||
public const string Version = "2.0.1";
|
||||
public const string Version = "2.0.2";
|
||||
}
|
||||
@@ -594,9 +594,9 @@ public class SquidWTFMetadataService : TrackParserBase, IMusicMetadataService
|
||||
|
||||
try
|
||||
{
|
||||
return await _fallbackHelper.RaceTopEndpointsAsync(
|
||||
return await _fallbackHelper.RaceTopEndpointsAsync<Song?>(
|
||||
raceCount,
|
||||
(baseUrl, ct) => FetchSongAsync(baseUrl, externalId, ct),
|
||||
async (baseUrl, ct) => await FetchSongAsync(baseUrl, externalId, ct),
|
||||
cancellationToken);
|
||||
}
|
||||
catch (Exception ex)
|
||||
@@ -608,9 +608,9 @@ public class SquidWTFMetadataService : TrackParserBase, IMusicMetadataService
|
||||
}
|
||||
}
|
||||
|
||||
return await _fallbackHelper.TryWithFallbackAsync(
|
||||
baseUrl => FetchSongAsync(baseUrl, externalId, cancellationToken),
|
||||
(Song?)null);
|
||||
return await _fallbackHelper.TryWithFallbackAsync<Song?>(
|
||||
async baseUrl => await FetchSongAsync(baseUrl, externalId, cancellationToken),
|
||||
null);
|
||||
}
|
||||
|
||||
private async Task<Song> FetchSongAsync(string baseUrl, string externalId, CancellationToken cancellationToken)
|
||||
|
||||
Reference in new issue
Block a user