aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLuke Pulverenti <luke.pulverenti@gmail.com>2013-11-15 10:11:35 -0500
committerLuke Pulverenti <luke.pulverenti@gmail.com>2013-11-15 10:11:35 -0500
commitd81349036337c423f5826c519fc38badf2ad033f (patch)
tree23cda56afffc334c36d898175a5f9c1837b396b6
parentad3e4dee0e8eaa21fbb0b24958a0dfdb6be7cc76 (diff)
fix remote image service not ensuring save directory existence
-rw-r--r--MediaBrowser.Api/Images/RemoteImageService.cs2
1 files changed, 2 insertions, 0 deletions
diff --git a/MediaBrowser.Api/Images/RemoteImageService.cs b/MediaBrowser.Api/Images/RemoteImageService.cs
index f92d9d581..1084e99d0 100644
--- a/MediaBrowser.Api/Images/RemoteImageService.cs
+++ b/MediaBrowser.Api/Images/RemoteImageService.cs
@@ -359,6 +359,8 @@ namespace MediaBrowser.Api.Images
var fullCachePath = GetFullCachePath(urlHash + "." + ext);
+ Directory.CreateDirectory(Path.GetDirectoryName(fullCachePath));
+
using (var stream = result.Content)
{
using (var filestream = _fileSystem.GetFileStream(fullCachePath, FileMode.Create, FileAccess.Write, FileShare.Read, true))