Fix for NPE while loading data

This commit is contained in:
Brendan Robert 2018-01-24 01:20:03 -06:00
parent 0ddc073a3d
commit eb61a9f8ff

View File

@ -98,6 +98,9 @@ public class DataUtilities {
private static void logScripts(Scripts scripts, PrintWriter logger) { private static void logScripts(Scripts scripts, PrintWriter logger) {
if (scripts != null && scripts.getScript() != null || !scripts.getScript().isEmpty()) { if (scripts != null && scripts.getScript() != null || !scripts.getScript().isEmpty()) {
scripts.getScript().forEach((script) -> { scripts.getScript().forEach((script) -> {
if (script.getBlock() == null) {
return;
}
Queue<Block> evaluateStack = new ArrayDeque<>(); Queue<Block> evaluateStack = new ArrayDeque<>();
evaluateStack.add(script.getBlock()); evaluateStack.add(script.getBlock());
int blockCount = 0; int blockCount = 0;