]> git.mxchange.org Git - friendica.git/blobdiff - src/Object/Image.php
spelling: occurred
[friendica.git] / src / Object / Image.php
index 00f8f3c5bbe89553a3c7932168b9de85fcacd1c2..49196a0c44fe6b1e379210330d37f4965386b996 100644 (file)
@@ -196,7 +196,7 @@ class Image
        public function isValid(): bool
        {
                if ($this->isImagick()) {
-                       return ($this->image !== false);
+                       return !empty($this->image);
                }
                return $this->valid;
        }
@@ -718,7 +718,7 @@ class Image
                                if ($image->isImagick()) {
                                        try {
                                                $colors = $image->image->getImagePixelColor($x, $y)->getColor();
-                                       } catch (\Throwable $th) {
+                                       } catch (\Exception $exception) {
                                                return '';
                                        }
                                        $row[] = [$colors['r'], $colors['g'], $colors['b']];