Skip to content

Commit 87e9d89

Browse files
committed
Disable Imagick by default
1 parent 0683b93 commit 87e9d89

File tree

1 file changed

+3
-4
lines changed

1 file changed

+3
-4
lines changed

src/Identicon.php

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -211,11 +211,10 @@ public function setSize($size): void
211211
*/
212212
public function getEnableImageMagick(): bool
213213
{
214-
// Enable ImageMagick on PHP < 7. On PHP 7 the performance increase
215-
// is not as obvious as on PHP 5. Since the ImageMagick renderer has a
216-
// lot of quirks, we don't want to use it unless really needed.
214+
// Performance of using Imagick on PHP 7 and later is generally worse than using
215+
// the internal renderer. Because of this, default to false.
217216
if ($this->enableImageMagick === null) {
218-
return PHP_MAJOR_VERSION < 7 && extension_loaded('imagick');
217+
return false;
219218
}
220219

221220
return $this->enableImageMagick;

0 commit comments

Comments
 (0)