wow thats a rare bug

This commit is contained in:
Leijurv 2018-11-14 14:26:35 -08:00
parent 80d6d7fd58
commit 8385bc35ed
No known key found for this signature in database
GPG Key ID: 44A3EA646EADAC6A

View File

@ -193,7 +193,7 @@ public abstract class AbstractNodeCostSearch implements IPathFinder {
@Override
public Optional<IPath> bestPathSoFar() {
if (startNode == null || bestSoFar[0] == null) {
if (startNode == null || bestSoFar == null || bestSoFar[0] == null) {
return Optional.empty();
}
for (int i = 0; i < bestSoFar.length; i++) {