Commit 9b0631f0 authored by Geoffrey Métais's avatar Geoffrey Métais

Filter if Uri has query parameters

parent fc83d224
......@@ -137,7 +137,12 @@ public class MediaWrapper implements Parcelable {
}
if (mType == TYPE_ALL) {
final String location = mUri.toString();
final int index = mUri.toString().indexOf('?');
String location;
if (index == -1)
location = mUri.toString();
else
location = mUri.toString().substring(0, index);
int dotIndex = location.lastIndexOf(".");
if (dotIndex != -1) {
String fileExt = location.substring(dotIndex).toLowerCase(Locale.ENGLISH);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment