Skip to content
Snippets Groups Projects
Commit 386dc053 authored by Travis Ralston's avatar Travis Ralston
Browse files

Fix SVGs not always being thumbnailed

parent af45aaf8
No related branches found
No related tags found
No related merge requests found
......@@ -11,6 +11,7 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
* Fixed media purge API not being able to delete thumbnails.
* Fixed thumbnails being attempted for disabled media types.
* Fixed SVG and other non-dimensional media failing to be usefully thumbnailed in some cases.
## [1.3.0] - September 8, 2023
......
......@@ -53,7 +53,7 @@ func GenerateThumbnail(imgStream io.ReadCloser, contentType string, width int, h
// TODO: Why does AdjustProperties even take `canAnimate` if it's always been hardcoded to `false`? (see git blame on this comment)
var shouldThumbnail bool
shouldThumbnail, width, height, _, method = u.AdjustProperties(w, h, width, height, animated, false, method)
if !shouldThumbnail {
if !shouldThumbnail && dimensional {
return nil, common.ErrMediaDimensionsTooSmall
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment