From: Tara L Andrews Date: Fri, 24 Feb 2012 01:11:05 +0000 (+0100) Subject: fix change detection bug X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=7c293912d5aeee653131449d246a0f442dc8119f;p=scpubgit%2Fstemmatology.git fix change detection bug --- diff --git a/lib/Text/Tradition/Collation.pm b/lib/Text/Tradition/Collation.pm index 9ec858e..69b1a59 100644 --- a/lib/Text/Tradition/Collation.pm +++ b/lib/Text/Tradition/Collation.pm @@ -1366,7 +1366,8 @@ sub calculate_ranks { # Do we need to invalidate the cached data? if( $self->has_cached_svg || $self->has_cached_table ) { foreach my $r ( $self->readings ) { - next if $existing_ranks{$r} && $existing_ranks{$r} == $r->rank; + next if defined( $existing_ranks{$r} ) + && $existing_ranks{$r} == $r->rank; # Something has changed, so clear the cache $self->_clear_cache; # ...and recalculate the common readings.