Bug 15687: Fix xgettext.pl syntax errors

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
This commit is contained in:
Julian Maurice 2016-01-28 09:32:11 +01:00 committed by Brendan Gallagher
parent e140603a59
commit 70112cfb81

View file

@ -48,14 +48,14 @@ sub token_negligible_p {
my($x) = @_;
my $t = $x->type;
return !$extract_all_p && (
$t == C4::TmplTokenType::TEXT? string_negligible_p( $x->string ):
$t == C4::TmplTokenType::DIRECTIVE? 1:
$t == C4::TmplTokenType::TEXT_PARAMETRIZED
$t == C4::TmplTokenType::TEXT() ? string_negligible_p( $x->string ) :
$t == C4::TmplTokenType::DIRECTIVE() ? 1 :
$t == C4::TmplTokenType::TEXT_PARAMETRIZED()
&& join( '', map { my $t = $_->type;
$t == C4::TmplTokenType::DIRECTIVE?
'1': $t == C4::TmplTokenType::TAG?
'': token_negligible_p( $_ )?
'': '1' } @{$x->children} ) eq '' );
$t == C4::TmplTokenType::DIRECTIVE() ?
'1' : $t == C4::TmplTokenType::TAG() ?
'' : token_negligible_p( $_ ) ?
'' : '1' } @{$x->children} ) eq '' );
}
###############################################################################