mirror of
https://github.com/Karaka-Management/phpOMS.git
synced 2026-02-02 02:38:44 +00:00
Fix temp file name
This commit is contained in:
parent
dc53adec3c
commit
823f161451
|
|
@ -14,6 +14,8 @@ declare(strict_types=1);
|
|||
|
||||
namespace phpOMS\Utils\IO\Zip;
|
||||
|
||||
use phpOMS\System\File\Local\File;
|
||||
|
||||
/**
|
||||
* Zip class for handling zip files.
|
||||
*
|
||||
|
|
@ -54,12 +56,12 @@ class TarGz implements ArchiveInterface
|
|||
return false;
|
||||
}
|
||||
|
||||
if (!Gz::unpack($source, $destination . '.tmp')) {
|
||||
if (!Gz::unpack($source, $destination . File::name($source) . '.tmp')) {
|
||||
return false;
|
||||
}
|
||||
|
||||
$unpacked = Tar::unpack($destination . '.tmp', $destination);
|
||||
\unlink($destination . '.tmp');
|
||||
$unpacked = Tar::unpack($destination . File::name($source) . '.tmp', $destination);
|
||||
\unlink($destination . File::name($source) . '.tmp');
|
||||
|
||||
return $unpacked;
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user