Fetch token script images even if they aren't in the token image file

This commit is contained in:
tehdiplomat
2018-09-03 11:37:44 -04:00
parent 67edb87ccd
commit d220f5fb78

View File

@@ -75,10 +75,10 @@ public class ImageFetcher {
}
}
final String filename = imageKey.substring(2) + ".jpg";
final String tokenUrl = tokenImages.get(filename);
String tokenUrl = tokenImages.get(filename);
if (tokenUrl == null) {
System.err.println("Token " + imageKey + " not found in: " + ForgeConstants.IMAGE_LIST_TOKENS_FILE);
return;
System.err.println("No specified file.. Attempting to download from default Url");
tokenUrl = String.format("%s%s", ForgeConstants.URL_TOKEN_DOWNLOAD, filename);
}
destFile = new File(ForgeConstants.CACHE_TOKEN_PICS_DIR, filename);
downloadUrls.add(tokenUrl);