Avoid NullPointerException in getLastSubnodeChange().

Preliminary fix for bug 697 <http://dev.helma.org/bugs/show_bug.cgi?id=697>
This commit is contained in:
hns 2010-01-26 15:49:41 +00:00
parent b072860a45
commit 842d4fd92b

View file

@ -164,7 +164,7 @@ public class SubnodeList implements Serializable {
// include dbmap.getLastTypeChange to also reload if the type mapping has changed. // include dbmap.getLastTypeChange to also reload if the type mapping has changed.
long checkSum = lastSubnodeChange + node.dbmap.getLastTypeChange(); long checkSum = lastSubnodeChange + node.dbmap.getLastTypeChange();
Relation rel = getSubnodeRelation(); Relation rel = getSubnodeRelation();
return rel.aggressiveCaching ? return rel == null || rel.aggressiveCaching ?
checkSum : checkSum + rel.otherType.getLastDataChange(); checkSum : checkSum + rel.otherType.getLastDataChange();
} }