View | Details | Raw Unified | Return to bug 7961
Collapse All | Expand All

(-)a/tools/upload-cover-image.pl (-3 / +6 lines)
Lines 48-53 use C4::Auth; Link Here
48
use C4::Output;
48
use C4::Output;
49
use C4::Images;
49
use C4::Images;
50
use C4::UploadedFile;
50
use C4::UploadedFile;
51
use C4::Log;
51
52
52
my $debug = 1;
53
my $debug = 1;
53
54
Lines 143-152 if ($fileID) { Link Here
143
                            $error = 'DELERR';
144
                            $error = 'DELERR';
144
                        }
145
                        }
145
                        else {
146
                        else {
146
                            ( $biblionumber, $filename ) = split $delim, $line;
147
                            ( $biblionumber, $filename ) = split $delim, $line, 2;
147
                            $biblionumber =~
148
                            $biblionumber =~
148
                              s/[\"\r\n]//g;    # remove offensive characters
149
                              s/[\"\r\n]//g;    # remove offensive characters
149
                            $filename =~ s/[\"\r\n\s]//g;
150
                            $filename =~ s/[\"\r\n]//g;
151
                            $filename =~ s/^\s+//;
152
                            $filename =~ s/\s+$//;
153
                            logaction('CATALOGUING', 'MODIFY', $biblionumber, "cover image: $filename");
150
                            my $srcimage = GD::Image->new("$dir/$filename");
154
                            my $srcimage = GD::Image->new("$dir/$filename");
151
                            if ( defined $srcimage ) {
155
                            if ( defined $srcimage ) {
152
                                $total++;
156
                                $total++;
153
- 

Return to bug 7961