mirror of
https://github.com/hkalexling/Mango.git
synced 2026-03-20 00:00:48 -04:00
Support webp (#69, nice)
This commit is contained in:
@@ -224,7 +224,7 @@ class APIRouter < Router
|
||||
entry_id = env.params.query["entry"]?
|
||||
title = @context.library.get_title(title_id).not_nil!
|
||||
|
||||
unless ["image/jpeg", "image/png"].includes? \
|
||||
unless SUPPORTED_IMG_TYPES.includes? \
|
||||
MIME.from_filename? filename
|
||||
raise "The uploaded image must be either JPEG or PNG"
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user