From d6ee508022a1299776856490c07035852a21176e Mon Sep 17 00:00:00 2001 From: Andrey Kutejko Date: Fri, 2 Aug 2013 20:02:43 +0300 Subject: [PATCH] php 5.3 friendly --- ipf/command/pack.php | 3 ++- ipf/command/unpack.php | 9 ++++++--- 2 files changed, 8 insertions(+), 4 deletions(-) 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'); } } -- 2.49.0