From: tla Date: Fri, 16 Aug 2013 09:44:14 +0000 (+0200) Subject: Avoid an empty-string warning X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=c8010abfeccb5f260080e7ec295a39ea058a13d7;p=scpubgit%2Fstemmatology.git Avoid an empty-string warning --- diff --git a/base/lib/Text/Tradition/Parser/CTE.pm b/base/lib/Text/Tradition/Parser/CTE.pm index 6093066..a670d52 100644 --- a/base/lib/Text/Tradition/Parser/CTE.pm +++ b/base/lib/Text/Tradition/Parser/CTE.pm @@ -535,9 +535,9 @@ sub _add_lacunae { # Find the anchor, if any. This marks the point where the text starts # or ends. my $anchor = $app->getAttribute( 'to' ); - $anchor =~ s/^\#//; my $aname; if( $anchor ) { + $anchor =~ s/^\#//; $aname = _anchor_name( $anchor ); }