[Koha-bugs] [Bug 8218] Add a script to sanitize entity where "&" character was wrongly replaced with "& "
bugzilla-daemon at bugs.koha-community.org
bugzilla-daemon at bugs.koha-community.org
Wed Jul 18 12:48:16 CEST 2012
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8218
Jonathan Druart <jonathan.druart at biblibre.com> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|Signed Off |Failed QA
CC| |jonathan.druart at biblibre.co
| |m
Assignee|sophie.meynieux at biblibre.co |alex.arnaud at biblibre.com
|m |
--- Comment #5 from Jonathan Druart <jonathan.druart at biblibre.com> ---
QA Comments:
1/ Please use
use strict;
use warnings;
OR
use Modern::Perl;
2/ Perltidied for misc/maintenance/batchSanitizeEntity.pl
3/ Bad encoding (N°)
Technically:
4/ $count += 1; => $count++;
5/
+# We remove spaces
+my @biblio;
+foreach my $bib(@biblios) {
+ $bib =~ s/(^\s*|\s*$)//g;
+ next if $bib eq "";
+ push @biblio, $bib;
+}
+ at biblios = @biblio;
The second tmp array is useless:
# We remove spaces
s/(^\s*|\s*$)//g for @biblios;
# Remove empty lines
@biblios = grep {!/^$/} @biblios;
6/ if ($biblios =~ /\//)
is more readable as:
if ( $biblio =~ m|/| )
for example
7/ + while (my $bib = $sth-> fetchrow_array()){
There is a useless space ;-)
Marking as Failed QA for 1 and 2
--
You are receiving this mail because:
You are watching all bug changes.
More information about the Koha-bugs
mailing list