Fix GuiReplayViewer crashing when metadata of replay is missing
This commit is contained in:
@@ -86,12 +86,9 @@ public class GuiReplayViewer extends GuiScreen {
|
|||||||
}
|
}
|
||||||
final ReplayMetaData metaData = replayFile.getMetaData();
|
final ReplayMetaData metaData = replayFile.getMetaData();
|
||||||
|
|
||||||
obj.consume(new Supplier<GuiReplayEntry>() {
|
if (metaData != null) {
|
||||||
@Override
|
obj.consume(() -> new GuiReplayEntry(file, metaData, theThumb));
|
||||||
public GuiReplayEntry get() {
|
}
|
||||||
return new GuiReplayEntry(file, metaData, theThumb);
|
|
||||||
}
|
|
||||||
});
|
|
||||||
} catch (Exception e) {
|
} catch (Exception e) {
|
||||||
FMLLog.getLogger().error("Could not load Replay File " + file.getName(), e);
|
FMLLog.getLogger().error("Could not load Replay File " + file.getName(), e);
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user