From: Tara L Andrews Date: Sat, 29 Sep 2012 01:47:22 +0000 (+0200) Subject: safer existence check X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=308970243467c50d81e663a9e71ff1656f540fee;p=scpubgit%2Fstemmatology.git safer existence check --- diff --git a/base/lib/Text/Tradition/Collation.pm b/base/lib/Text/Tradition/Collation.pm index 18ccf07..3b9af97 100644 --- a/base/lib/Text/Tradition/Collation.pm +++ b/base/lib/Text/Tradition/Collation.pm @@ -489,7 +489,7 @@ sub del_path { if( $self->sequence->has_edge_attribute( $source, $target, $wit ) ) { $self->sequence->delete_edge_attribute( $source, $target, $wit ); } - unless( keys %{$self->sequence->get_edge_attributes( $source, $target )} ) { + unless( $self->sequence->has_edge_attributes( $source, $target ) ) { $self->sequence->delete_edge( $source, $target ); $self->relations->delete_equivalence_edge( $source, $target ); }