aboutsummaryrefslogtreecommitdiff
path: root/Jellyfin.Api/Controllers/ImageController.cs
diff options
context:
space:
mode:
authorcrobibero <cody@robibe.ro>2020-11-02 10:29:18 -0700
committercrobibero <cody@robibe.ro>2020-11-02 10:29:18 -0700
commitf8e6edbfeb8c437c2ed0a9c9b44bed0fc105b2c2 (patch)
tree67747afc55cc2ad162e533a6ba4141b65a3e55b8 /Jellyfin.Api/Controllers/ImageController.cs
parent11d69fd3b1c25927c1046c4a095a3bd9f29fa722 (diff)
parentb1b43b8ad9e6ecc905e1ff4270d4844494ed3039 (diff)
Merge remote-tracking branch 'upstream/master' into query-fields
Diffstat (limited to 'Jellyfin.Api/Controllers/ImageController.cs')
-rw-r--r--Jellyfin.Api/Controllers/ImageController.cs6
1 files changed, 3 insertions, 3 deletions
diff --git a/Jellyfin.Api/Controllers/ImageController.cs b/Jellyfin.Api/Controllers/ImageController.cs
index 05efe2355..4a67c1aed 100644
--- a/Jellyfin.Api/Controllers/ImageController.cs
+++ b/Jellyfin.Api/Controllers/ImageController.cs
@@ -109,7 +109,7 @@ namespace Jellyfin.Api.Controllers
var userDataPath = Path.Combine(_serverConfigurationManager.ApplicationPaths.UserConfigurationDirectoryPath, user.Username);
if (user.ProfileImage != null)
{
- _userManager.ClearProfileImage(user);
+ await _userManager.ClearProfileImageAsync(user).ConfigureAwait(false);
}
user.ProfileImage = new Data.Entities.ImageInfo(Path.Combine(userDataPath, "profile" + MimeTypes.ToExtension(mimeType)));
@@ -138,7 +138,7 @@ namespace Jellyfin.Api.Controllers
[SuppressMessage("Microsoft.Performance", "CA1801:ReviewUnusedParameters", MessageId = "index", Justification = "Imported from ServiceStack")]
[ProducesResponseType(StatusCodes.Status204NoContent)]
[ProducesResponseType(StatusCodes.Status403Forbidden)]
- public ActionResult DeleteUserImage(
+ public async Task<ActionResult> DeleteUserImage(
[FromRoute, Required] Guid userId,
[FromRoute, Required] ImageType imageType,
[FromRoute] int? index = null)
@@ -158,7 +158,7 @@ namespace Jellyfin.Api.Controllers
_logger.LogError(e, "Error deleting user profile image:");
}
- _userManager.ClearProfileImage(user);
+ await _userManager.ClearProfileImageAsync(user).ConfigureAwait(false);
return NoContent();
}