Skip to content

Commit

Permalink
Filename case fix
Browse files Browse the repository at this point in the history
  • Loading branch information
h4mu committed Apr 29, 2019
1 parent 385b717 commit 3492cc2
Showing 1 changed file with 7 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -152,10 +152,14 @@ private boolean isGameContentInstalled() {

@Override
public boolean accept(File dir, String filename) {
return "REMOTE1.RTS".equals(filename)
String upperCase = filename.toUpperCase();
if (!filename.equals(upperCase)) {
new File(dir, filename).renameTo(new File(dir, upperCase));
}
return "REMOTE1.RTS".equals(upperCase)
|| (isShareware()
? "HUNTBGIN.RTL".equals(filename) || "HUNTBGIN.WAD".equals(filename)
: "DARKWAR.RTL".equals(filename) || "DARKWAR.WAD".equals(filename));
? "HUNTBGIN.RTL".equals(upperCase) || "HUNTBGIN.WAD".equals(upperCase)
: "DARKWAR.RTL".equals(upperCase) || "DARKWAR.WAD".equals(upperCase));
}

}).length >= 3;
Expand Down

0 comments on commit 3492cc2

Please sign in to comment.