thumb: catch php errors during (gd) resize
[minimedit.git] / thumb / index.php
index 532499f6aa2f14f3cd2f4aea9dbd7481ae9feea5..1d369488c927b78399d9a2e208559286a109c595 100644 (file)
@@ -16,7 +16,7 @@ if (!file_exists($imgpath)) {
 try {
        $target = mkthumb($imgpath, $width, $height);
 }
-catch (Exception $e) {
+catch (Throwable $e) {
        http_response_code($e->getCode() ?: 500);
        $target = '500.png';
        if (file_exists($target)) {