Bug 15005: Replace $ENV{SCRIPT_NAME} with the hardcoded script paths
[koha_ffzg] / tools / batch_record_modification.pl
index f275088..60775a9 100755 (executable)
@@ -156,7 +156,7 @@ if ( $op eq 'form' ) {
     my ( $job );
     if ( $runinbackground ) {
         my $job_size = scalar( @record_ids );
-        $job = C4::BackgroundJob->new( $sessionID, "FIXME", $ENV{SCRIPT_NAME}, $job_size );
+        $job = C4::BackgroundJob->new( $sessionID, "FIXME", '/cgi-bin/koha/tools/batch_record_modification.pl', $job_size );
         my $job_id = $job->id;
         if (my $pid = fork) {
             $dbh->{InactiveDestroy}  = 1;
@@ -169,7 +169,7 @@ if ( $op eq 'form' ) {
             close STDOUT;
             close STDERR;
         } else {
-            warn "fork failed while attempting to run $ENV{'SCRIPT_NAME'} as a background job";
+            warn "fork failed while attempting to run tools/batch_record_modification.pl as a background job";
             exit 0;
         }
     }