diff options
| author | Vasily <just.one.man@yandex.ru> | 2020-05-27 15:01:03 +0300 |
|---|---|---|
| committer | Vasily <just.one.man@yandex.ru> | 2020-05-27 15:01:03 +0300 |
| commit | 6c9dc0418961a673f9e5dcfb36f66d076381a92e (patch) | |
| tree | 7ea060824e36144fca58eaccd7330e8bc580a61e /Emby.Server.Implementations/Library/LibraryManager.cs | |
| parent | f575415e0b611cbfb4139e9e9c816adcb000442e (diff) | |
Handle errors during blurhash generation so it does not fail the scan
Diffstat (limited to 'Emby.Server.Implementations/Library/LibraryManager.cs')
| -rw-r--r-- | Emby.Server.Implementations/Library/LibraryManager.cs | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/Emby.Server.Implementations/Library/LibraryManager.cs b/Emby.Server.Implementations/Library/LibraryManager.cs index e63776bff..903c0b3cf 100644 --- a/Emby.Server.Implementations/Library/LibraryManager.cs +++ b/Emby.Server.Implementations/Library/LibraryManager.cs @@ -1841,7 +1841,15 @@ namespace Emby.Server.Implementations.Library ImageDimensions size = _imageProcessor.GetImageDimensions(item, img); img.Width = size.Width; img.Height = size.Height; - img.BlurHash = _imageProcessor.GetImageBlurHash(img.Path); + try + { + img.BlurHash = _imageProcessor.GetImageBlurHash(img.Path); + } + catch (Exception ex) + { + _logger.LogError(ex, "Cannot compute blurhash for {0}", img.Path); + img.BlurHash = string.Empty; + } }); _itemRepository.SaveImages(item); |
