Completed
Push — master ( 14d951...94c0bf )
by Basil
05:03
created
envs/dev/properties/TestProperty.php 1 patch
Unused Use Statements   -2 removed lines patch added patch discarded remove patch
@@ -2,8 +2,6 @@
 block discarded – undo
2 2
 
3 3
 namespace app\properties;
4 4
 
5
-use Yii;
6
-
7 5
 class TestProperty extends \admin\base\Property
8 6
 {
9 7
     public function init()
Please login to merge, or discard this patch.
modules/admin/apis/StorageController.php 1 patch
Unused Use Statements   -1 removed lines patch added patch discarded remove patch
@@ -5,7 +5,6 @@
 block discarded – undo
5 5
 use Yii;
6 6
 use Exception;
7 7
 use admin\helpers\Storage;
8
-use admin\models\StorageImage;
9 8
 use admin\models\StorageFile;
10 9
 use admin\models\StorageFolder;
11 10
 use admin\Module;
Please login to merge, or discard this patch.
modules/admin/controllers/DefaultController.php 2 patches
Unused Use Statements   -1 removed lines patch added patch discarded remove patch
@@ -3,7 +3,6 @@
 block discarded – undo
3 3
 namespace admin\controllers;
4 4
 
5 5
 use Yii;
6
-use admin\Module;
7 6
 use luya\helpers\Url;
8 7
 use yii\helpers\Json;
9 8
 
Please login to merge, or discard this patch.
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -14,10 +14,10 @@
 block discarded – undo
14 14
     public function actionIndex()
15 15
     {
16 16
         // register auth token
17
-        $this->view->registerJs("var authToken='".Yii::$app->adminuser->identity->authToken ."';", \luya\web\View::POS_HEAD);
17
+        $this->view->registerJs("var authToken='".Yii::$app->adminuser->identity->authToken."';", \luya\web\View::POS_HEAD);
18 18
         $this->view->registerJs("var homeUrl='".Url::home(true)."';", \luya\web\View::POS_HEAD);
19 19
         // register admin js translations from module
20
-        $this->view->registerJs('var i18n=' . Json::encode($this->module->jsTranslations), \luya\web\View::POS_HEAD);
20
+        $this->view->registerJs('var i18n='.Json::encode($this->module->jsTranslations), \luya\web\View::POS_HEAD);
21 21
         // Init ElementQueries after page load
22 22
         // $this->view->registerJs('setTimeout( function() {ElementQueries.listen(); ElementQueries.init();}, 1500);', \luya\web\View::POS_LOAD);
23 23
         // return and render index view file
Please login to merge, or discard this patch.
modules/cmsadmin/apis/MenuController.php 1 patch
Unused Use Statements   -1 removed lines patch added patch discarded remove patch
@@ -4,7 +4,6 @@
 block discarded – undo
4 4
 
5 5
 use yii\db\Query;
6 6
 use luya\helpers\ArrayHelper;
7
-use cmsadmin\models\NavContainer;
8 7
 use admin\models\Lang;
9 8
 
10 9
 class MenuController extends \admin\base\RestController
Please login to merge, or discard this patch.
modules/crawler/classes/CrawlPage.php 2 patches
Unused Use Statements   -1 removed lines patch added patch discarded remove patch
@@ -5,7 +5,6 @@
 block discarded – undo
5 5
 use Goutte\Client;
6 6
 use yii\base\InvalidConfigException;
7 7
 use yii\base\yii\base;
8
-use luya\helpers\Url;
9 8
 
10 9
 class CrawlPage extends \yii\base\Object
11 10
 {
Please login to merge, or discard this patch.
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -32,7 +32,7 @@  discard block
 block discarded – undo
32 32
         
33 33
         $info = parse_url($this->baseUrl);
34 34
         
35
-        $this->baseHost = $info['scheme'] . '://' . $info['host'];
35
+        $this->baseHost = $info['scheme'].'://'.$info['host'];
36 36
     }
37 37
 
38 38
     public function flush()
@@ -59,7 +59,7 @@  discard block
 block discarded – undo
59 59
     
60 60
     public function getLinks()
61 61
     {
62
-        $links = $this->getCrawler()->filterXPath('//a')->each(function ($node, $i) {
62
+        $links = $this->getCrawler()->filterXPath('//a')->each(function($node, $i) {
63 63
             return $node->extract(array('_text', 'href'))[0];
64 64
         });
65 65
         foreach ($links as $key => $item) {
@@ -68,7 +68,7 @@  discard block
 block discarded – undo
68 68
             if (!isset($url['host']) || !isset($url['scheme'])) {
69 69
                 $base = $this->baseHost;
70 70
             } else {
71
-                $base = $url['scheme'] . '//' . $url['host'];
71
+                $base = $url['scheme'].'//'.$url['host'];
72 72
             }
73 73
             
74 74
             $path = null;
@@ -77,7 +77,7 @@  discard block
 block discarded – undo
77 77
                 $path = $url['path'];
78 78
             }
79 79
             
80
-            $url = rtrim($base, "/") . "/" . ltrim($path, "/");
80
+            $url = rtrim($base, "/")."/".ltrim($path, "/");
81 81
             
82 82
 
83 83
             $links[$key][1] = http_build_url($url, [
Please login to merge, or discard this patch.
core/helpers/ArrayHelper.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -29,7 +29,7 @@
 block discarded – undo
29 29
         
30 30
         foreach ($array as $k => $v) {
31 31
             if (is_numeric($v)) {
32
-                $return[$k] = (int)$v;
32
+                $return[$k] = (int) $v;
33 33
             } elseif (is_array($v)) {
34 34
                 $return[$k] = self::typeCast($v);
35 35
             } else {
Please login to merge, or discard this patch.
core/web/UrlManager.php 2 patches
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -48,7 +48,7 @@  discard block
 block discarded – undo
48 48
         if ($route === $composition) {
49 49
             $parsedRequest[0] = false;
50 50
         // now see if the composition (+1 as we add add trailing slash at the end) matches the cutted route request part, if so its composition prefix, remove it.
51
-        } elseif (substr($route, 0, $length+1) == $composition.'/') {
51
+        } elseif (substr($route, 0, $length + 1) == $composition.'/') {
52 52
             $parsedRequest[0] = substr($parsedRequest[0], $length);
53 53
         }
54 54
         // fix broken request urls
@@ -211,10 +211,10 @@  discard block
 block discarded – undo
211 211
         $params = (array) $params;
212 212
         $url = $this->internalCreateUrl($params);
213 213
         if (strpos($url, '://') === false) {
214
-            $url = $this->getHostInfo() . $url;
214
+            $url = $this->getHostInfo().$url;
215 215
         }
216 216
         if (is_string($scheme) && ($pos = strpos($url, '://')) !== false) {
217
-            $url = $scheme . substr($url, $pos);
217
+            $url = $scheme.substr($url, $pos);
218 218
         }
219 219
         return $url;
220 220
     }
Please login to merge, or discard this patch.
Unused Use Statements   -1 removed lines patch added patch discarded remove patch
@@ -5,7 +5,6 @@
 block discarded – undo
5 5
 use Goutte\Client;
6 6
 use yii\base\InvalidConfigException;
7 7
 use yii\base\yii\base;
8
-use luya\helpers\Url;
9 8
 
10 9
 class CrawlPage extends \yii\base\Object
11 10
 {
Please login to merge, or discard this patch.
core/web/Twig.php 1 patch
Spacing   +11 added lines, -11 removed lines patch added patch discarded remove patch
@@ -30,38 +30,38 @@  discard block
 block discarded – undo
30 30
     public function getFunctions()
31 31
     {
32 32
         return [
33
-            'menuFindAll' => function ($container, $parentNavId) {
33
+            'menuFindAll' => function($container, $parentNavId) {
34 34
                 return Yii::$app->menu->findAll(['container' => $container, 'parent_nav_id' => $parentNavId]);
35 35
             },
36
-            'menuFindOne' => function ($id) {
36
+            'menuFindOne' => function($id) {
37 37
                 return Yii::$app->menu->findOne(['id' => $id]);
38 38
             },
39
-            'menuCurrent' => function () {
39
+            'menuCurrent' => function() {
40 40
                 return Yii::$app->menu->current;
41 41
             },
42
-            'menuCurrentLevel' => function ($level) {
42
+            'menuCurrentLevel' => function($level) {
43 43
                 return Yii::$app->menu->getLevelCurrent($level);
44 44
             },
45
-            'menuLevelContainer' => function ($level) {
45
+            'menuLevelContainer' => function($level) {
46 46
                 return Yii::$app->menu->getLevelContainer($level);
47 47
             },
48
-            'asset' => function ($name) {
48
+            'asset' => function($name) {
49 49
                 return Yii::$app->getAssetManager()->getBundle($name);
50 50
             },
51
-            'filterApply' => function ($imageId, $filterIdentifier) {
51
+            'filterApply' => function($imageId, $filterIdentifier) {
52 52
                 return Yii::$app->storage->getImage($imageId)->applyFilter($filterIdentifier);
53 53
             },
54
-            'image' => function ($imageId) {
54
+            'image' => function($imageId) {
55 55
                 return Yii::$app->storage->getImage($imageId);
56 56
             },
57
-            'element' => function () {
57
+            'element' => function() {
58 58
                 $args = func_get_args();
59 59
                 $method = $args[0];
60 60
                 unset($args[0]);
61 61
 
62 62
                 return Yii::$app->element->run($method, $args);
63 63
             },
64
-            't' => function () {
64
+            't' => function() {
65 65
                 $args = func_get_args();
66 66
 
67 67
                 return call_user_func_array(['Yii', 't'], $args);
@@ -79,7 +79,7 @@  discard block
 block discarded – undo
79 79
             $twig->addFunction(new Twig_SimpleFunction($name, $lambda));
80 80
         }
81 81
         
82
-        $twig->addFilter(new Twig_SimpleFilter('strftime', function ($timestamp, $format) {
82
+        $twig->addFilter(new Twig_SimpleFilter('strftime', function($timestamp, $format) {
83 83
             if (is_numeric($timestamp)) {
84 84
                 return strftime($format, $timestamp);
85 85
             }
Please login to merge, or discard this patch.
core/console/Command.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -75,7 +75,7 @@
 block discarded – undo
75 75
             $name = substr($name, 0, -(strlen($suffix)));
76 76
         }
77 77
     
78
-        return $name . $suffix;
78
+        return $name.$suffix;
79 79
     }
80 80
     
81 81
     /**
Please login to merge, or discard this patch.