Skip to content
Snippets Groups Projects
Commit ad3e02f5 authored by Sébastien Blin's avatar Sébastien Blin
Browse files

misc: fix crash on invalid iterator

Change-Id: I7a5eb63fb2d6ad08e4826905e873bcbe95bf2a0b
GitLab: #860
parent 4a429072
No related branches found
No related tags found
No related merge requests found
......@@ -589,7 +589,7 @@ MessagesAdapter::isLocalImage(const QString& mimename)
[fileFormat](QByteArray format) {
return format == fileFormat;
});
if (*iterator == "gif") {
if (iterator != supportedFormats.end() && *iterator == "gif") {
return {{"isAnimatedImage", true}};
}
return {{"isImage", iterator != supportedFormats.end()}};
......
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