Skip to content

Commit

Permalink
Fix for CamelCase extensions
Browse files Browse the repository at this point in the history
  • Loading branch information
4eRTuk committed Oct 6, 2015
1 parent c4d1f33 commit 32f6980
Showing 1 changed file with 3 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -318,18 +318,15 @@ protected void onActivityResult(
Log.d(TAG, "File Uri: " + uri.toString());
//check the file type from extension
String fileName = FileUtil.getFileNameByUri(this, uri, "");
if (fileName.endsWith("zip") ||
fileName.endsWith("ZIP")) { //create local tile layer
if (fileName.toLowerCase().endsWith("zip")) { //create local tile layer
if (null != mMapFragment) {
mMapFragment.addLocalTMSLayer(uri);
}
} else if (fileName.endsWith("geojson") ||
fileName.endsWith("GEOJSON")) { //create local vector layer
} else if (fileName.toLowerCase().endsWith("geojson")) { //create local vector layer
if (null != mMapFragment) {
mMapFragment.addLocalVectorLayer(uri);
}
} else if (fileName.endsWith("ngfp") ||
fileName.endsWith("NGFP")) { //create local vector layer with form
} else if (fileName.toLowerCase().endsWith("ngfp")) { //create local vector layer with form
if (null != mMapFragment) {
mMapFragment.addLocalVectorLayerWithForm(uri);
}
Expand Down

0 comments on commit 32f6980

Please sign in to comment.