Skip to content

Commit f5be89e

Browse files
JaredDavis22ctrueden
authored andcommitted
Only set lastHit with a non-null value.
1 parent 49a711b commit f5be89e

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

‎src/main/java/org/scijava/parsington/ParseOperation.java‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -251,7 +251,7 @@ protected Operator parseOperator() {
251251
int last = expression.length();
252252
while ((ndx < last) && (node != null)) {
253253
node = node.hasValueNext(expression.charAt(ndx++));
254-
if (node != null) lastHit = node.payload;
254+
if ((node != null) && (node.payload != null)) lastHit = node.payload;
255255
}
256256
if (lastHit != null) {
257257
for (Operator op : lastHit) {

0 commit comments

Comments
 (0)