mirror of
https://github.com/Prowlarr/Prowlarr.git
synced 2025-10-01 07:55:22 +02:00
Fixed: Error handling of valid, empty responses from Plex Media Server
This commit is contained in:
@@ -240,6 +240,11 @@ namespace NzbDrone.Core.Notifications.Plex
|
||||
throw new PlexAuthenticationException("Unauthorized - Username or password is incorrect");
|
||||
}
|
||||
|
||||
if (response.Content.IsNullOrWhiteSpace())
|
||||
{
|
||||
_logger.Trace("No response body returned, no error detected");
|
||||
}
|
||||
|
||||
var error = response.Content.Contains("_children") ?
|
||||
Json.Deserialize<PlexError>(response.Content) :
|
||||
Json.Deserialize<PlexResponse<PlexError>>(response.Content).MediaContainer;
|
||||
|
Reference in New Issue
Block a user