1 Commits

Author SHA1 Message Date
FrigaT
b6f78da9c8 dispose
All checks were successful
Release / pack-and-publish (release) Successful in 37s
2026-04-20 14:47:43 +03:00

View File

@@ -24,7 +24,6 @@ public class YandexMusicClient : IDisposable
private readonly YandexMusicApi _api;
private readonly AuthStorage _storage;
private readonly HttpClient _httpClient;
private readonly bool _ownsHttpClient;
private YnisonPlayer? _player;
/// <summary>Хранилище авторизации.</summary>
@@ -417,8 +416,7 @@ public class YandexMusicClient : IDisposable
{
if (_disposed) return;
_player?.Dispose();
if (_ownsHttpClient)
_httpClient.Dispose();
_httpClient.Dispose();
_disposed = true;
GC.SuppressFinalize(this);
}