Skip to content
Snippets Groups Projects
Commit 54b1b5c9 authored by srosse's avatar srosse
Browse files

OO-4549: fix rs if content type of an image cannot be guessed

parent a9c5eeb0
No related branches found
No related tags found
No related merge requests found
......@@ -303,6 +303,8 @@ public class ImageComponent extends AbstractComponent implements Disposable {
}
protected String getSuffix(String contentType) {
if(!StringHelper.containsNonWhitespace(contentType)) return null;
contentType = contentType.toLowerCase();
if(contentType.indexOf("jpg") >= 0 || contentType.indexOf("jpeg") >= 0) {
return "jpg";
......
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