Unnecessarily spammy logs for getThumbnail()
When trying to create thumbnails for remote media that don't have the filename field set, we got a lot of output in the debug log.
This commit is contained in:
parent
a8e613e508
commit
97812549b9
@ -110,6 +110,9 @@ class ImageFile
|
||||
$imgPath = null;
|
||||
$media = common_get_mime_media($file->mimetype);
|
||||
if (Event::handle('CreateFileImageThumbnailSource', array($file, &$imgPath, $media))) {
|
||||
if (empty($file->filename)) {
|
||||
throw new UnsupportedMediaException(_('File without filename could not get a thumbnail source.'));
|
||||
}
|
||||
switch ($media) {
|
||||
case 'image':
|
||||
$imgPath = $file->getPath();
|
||||
|
Loading…
Reference in New Issue
Block a user