From 4e2be47479e95dd8ac1906342edd8d489168078b Mon Sep 17 00:00:00 2001 From: Flavio Copes Date: Tue, 1 Mar 2016 19:50:12 +0100 Subject: [PATCH] Lint gpm --- classes/gpm.php | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/classes/gpm.php b/classes/gpm.php index 2b429e4b..45f35d9c 100644 --- a/classes/gpm.php +++ b/classes/gpm.php @@ -9,10 +9,16 @@ use Grav\Common\GPM\Upgrader; use Grav\Common\Filesystem\Folder; use Grav\Common\GPM\Common\Package; +/** + * Class Gpm + * @package Grav\Plugin\Admin + */ class Gpm { // Probably should move this to Grav DI container? + /** @var GravGPM */ protected static $GPM; + public static function GPM() { if (!static::$GPM) { @@ -86,8 +92,6 @@ class Gpm Installer::install($local, $options['destination'], ['install_path' => $package->install_path, 'theme' => $options['theme']]); Folder::delete(dirname($local)); - $errorCode = Installer::lastErrorCode(); - if (Installer::lastErrorCode() & (Installer::ZIP_OPEN_ERROR | Installer::ZIP_EXTRACT_ERROR)) { return false; }