Fix replay not being closed when opened via URI scheme handler (fixes #92)

This commit is contained in:
Jonas Herzig
2017-08-25 15:13:27 +02:00
parent 767ea292a7
commit 00e999ffd2
2 changed files with 5 additions and 0 deletions

View File

@@ -181,6 +181,9 @@ public class ReplayModReplay {
}
public void startReplay(ReplayFile replayFile, boolean checkModCompat) throws IOException {
if (replayHandler != null) {
replayHandler.endReplay();
}
if (checkModCompat) {
ModCompat.ModInfoDifference modDifference = new ModCompat.ModInfoDifference(replayFile.getModInfo());
if (!modDifference.getMissing().isEmpty() || !modDifference.getDiffering().isEmpty()) {