diff --git a/PVE/API2/Storage/Status.pm b/PVE/API2/Storage/Status.pm index fd82e53..e12b62a 100644 --- a/PVE/API2/Storage/Status.pm +++ b/PVE/API2/Storage/Status.pm @@ -498,14 +498,7 @@ __PACKAGE__->register_method ({ print "finished file import successfully\n"; }; - my $upid = $rpcenv->fork_worker('imgcopy', undef, $user, $worker); - - # apache removes the temporary file on return, so we need - # to wait here to make sure the worker process starts and - # opens the file before it gets removed. - sleep(1); - - return $upid; + return $rpcenv->fork_worker('imgcopy', undef, $user, $worker); }}); __PACKAGE__->register_method({