Skip to content

Commit 3ea6fcd

Browse files
holantomasdg
authored andcommitted
FileUpload: Added Webp content type to isImage (#132)
According to content types in `Nette\Utils\Image` added `image/webp` to `isImage()` method
1 parent 237bb58 commit 3ea6fcd

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

src/Http/FileUpload.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -167,7 +167,7 @@ function ($message) use ($dest) {
167167
*/
168168
public function isImage(): bool
169169
{
170-
return in_array($this->getContentType(), ['image/gif', 'image/png', 'image/jpeg'], true);
170+
return in_array($this->getContentType(), ['image/gif', 'image/png', 'image/jpeg', 'image/webp'], true);
171171
}
172172

173173

0 commit comments

Comments
 (0)