We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents 2708aa1 + 5ec5f40 commit cb08480Copy full SHA for cb08480
src/Symfony/Component/Validator/Constraints/Image.php
@@ -58,7 +58,7 @@ class Image extends File
58
self::CORRUPTED_IMAGE_ERROR => 'CORRUPTED_IMAGE_ERROR',
59
];
60
61
- public array|string $mimeTypes = 'image/*';
+ public array|string $mimeTypes = [];
62
public ?int $minWidth = null;
63
public ?int $maxWidth = null;
64
public ?int $maxHeight = null;
@@ -226,7 +226,7 @@ public function __construct(
226
$this->allowPortraitMessage = $allowPortraitMessage ?? $this->allowPortraitMessage;
227
$this->corruptedMessage = $corruptedMessage ?? $this->corruptedMessage;
228
229
- if (null === $this->mimeTypes && [] === $this->extensions) {
+ if ([] === $this->mimeTypes && [] === $this->extensions) {
230
$this->mimeTypes = 'image/*';
231
}
232
0 commit comments