From: Andrey Kutejko Date: Fri, 2 Aug 2013 17:02:43 +0000 (+0300) Subject: php 5.3 friendly X-Git-Tag: 0.5~94 X-Git-Url: https://git.andy128k.dev/?a=commitdiff_plain;h=d6ee508022a1299776856490c07035852a21176e;p=ipf.git php 5.3 friendly --- diff --git a/ipf/command/pack.php b/ipf/command/pack.php index b5a1e27..b2492cb 100644 --- a/ipf/command/pack.php +++ b/ipf/command/pack.php @@ -19,7 +19,8 @@ class IPF_Command_Pack chdir($workingDirectory); } - (new IPF_Command_DBDump)->run(array('--quiet')); + $dumpCommand = new IPF_Command_DBDump; + $dumpCommand->run(array('--quiet')); IPF_Shell::unlink($outputFileName); diff --git a/ipf/command/unpack.php b/ipf/command/unpack.php index 7d4453a..639d7f0 100644 --- a/ipf/command/unpack.php +++ b/ipf/command/unpack.php @@ -17,13 +17,16 @@ class IPF_Command_Unpack IPF_Shell::unlink('upload.tar'); IPF_Shell::unlink('dump.sql'); - (new Archive_Tar($inputFileName))->extract('.'); + $archive = new Archive_Tar($inputFileName); + $archive->extract('.'); - (new IPF_Command_DBRestore)->run(array('--quiet')); + $restoreCommand = new IPF_Command_DBRestore; + $restoreCommand->run(array('--quiet')); IPF_Shell::unlink('dump.sql'); $uploadsDir = IPF::get('document_root') . IPF::getUploadUrl(); - (new Archive_Tar('upload.tar'))->extract($uploadsDir . '/..'); + $archive = new Archive_Tar('upload.tar'); + $archive->extract($uploadsDir . '/..'); IPF_Shell::unlink('upload.tar'); } }