X-Git-Url: http://source.bookstackapp.com/bookstack/blobdiff_plain/9d8a1761822ff807cade093c72e2ba940ed38109..refs/pull/679/head:/app/Repos/ImageRepo.php diff --git a/app/Repos/ImageRepo.php b/app/Repos/ImageRepo.php index 8ddde7b0f..5f04a74b1 100644 --- a/app/Repos/ImageRepo.php +++ b/app/Repos/ImageRepo.php @@ -183,7 +183,6 @@ class ImageRepo * Get the thumbnail for an image. * If $keepRatio is true only the width will be used. * Checks the cache then storage to avoid creating / accessing the filesystem on every check. - * * @param Image $image * @param int $width * @param int $height @@ -194,9 +193,9 @@ class ImageRepo { try { return $this->imageService->getThumbnail($image, $width, $height, $keepRatio); - } catch (FileNotFoundException $exception) { - $image->delete(); - return []; + } catch (\Exception $exception) { + dd($exception); + return null; } }