JAL-2909 recognise .bam extension in URL and allow location spec as suffix - e.g...
[jalview.git] / src / jalview / io / IdentifyFile.java
index 38414e3..e65101d 100755 (executable)
@@ -127,9 +127,10 @@ public class IdentifyFile
         {
           // jar files are special - since they contain all sorts of random
           // characters.
-          if (source.inFile != null)
+          if (source.inFile != null || source.getDataName() != null)
           {
-            String fileStr = source.inFile.getName();
+            String fileStr = source.inFile == null ? source.getDataName()
+                    : source.inFile.getName();
             // possibly a Jalview archive.
             if (fileStr.lastIndexOf(".jar") > -1
                     || fileStr.lastIndexOf(".zip") > -1)