diff --git a/cataloguing/additem.pl b/cataloguing/additem.pl index b052cbcafd..6dc190a213 100755 --- a/cataloguing/additem.pl +++ b/cataloguing/additem.pl @@ -532,10 +532,12 @@ foreach my $tag (sort keys %{$tagslib}) { if (do $plugin) { my $extended_param = plugin_parameters( $dbh, $temp, $tagslib, $subfield_data{id}, \@loop_data ); my ( $function_name, $javascript ) = plugin_javascript( $dbh, $temp, $tagslib, $subfield_data{id}, \@loop_data ); - my $change= index($javascript, 'function Change')>-1?"return Change$function_name($subfield_data{random}, '$subfield_data{id}');": 'return 1;'; #enhancement 4866 + my $change = index($javascript, 'function Change') > -1 ? + "return Change$function_name($subfield_data{random}, '$subfield_data{id}');" : + 'return 1;'; $subfield_data{marc_value} = qq[ ... $javascript];