Completed
Push — master ( 658920...8dc597 )
by Andrey
02:37
created
Widget.php 2 patches
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -11,7 +11,7 @@  discard block
 block discarded – undo
11 11
     private static $routing;
12 12
     private static $property;
13 13
 
14
-    public function __construct(){
14
+    public function __construct() {
15 15
         # Config
16 16
         self::$config = (new Config)->instance()->config;
17 17
         # Application
@@ -26,15 +26,15 @@  discard block
 block discarded – undo
26 26
         self::$routing = new Routing;
27 27
     }
28 28
 
29
-    public function __get($name){
30
-        self::$property= $name;
29
+    public function __get($name) {
30
+        self::$property = $name;
31 31
         return new self;
32 32
     }
33 33
 
34
-    public function __call($_name,$value){
35
-        if(isset($value[0]) && !empty($value[0]) && is_array($value[0])) extract($value[0]);
34
+    public function __call($_name, $value) {
35
+        if (isset($value[0]) && !empty($value[0]) && is_array($value[0])) extract($value[0]);
36 36
         $file = self::$config['paths']['widget'].'/'.self::$property.'/'.$_name.'.phtml';
37
-        if(is_file($file)) require($file);
37
+        if (is_file($file)) require($file);
38 38
     }
39 39
 
40 40
 }
Please login to merge, or discard this patch.
Braces   +6 added lines, -2 removed lines patch added patch discarded remove patch
@@ -32,9 +32,13 @@
 block discarded – undo
32 32
     }
33 33
 
34 34
     public function __call($_name,$value){
35
-        if(isset($value[0]) && !empty($value[0]) && is_array($value[0])) extract($value[0]);
35
+        if(isset($value[0]) && !empty($value[0]) && is_array($value[0])) {
36
+            extract($value[0]);
37
+        }
36 38
         $file = self::$config['paths']['widget'].'/'.self::$property.'/'.$_name.'.phtml';
37
-        if(is_file($file)) require($file);
39
+        if(is_file($file)) {
40
+            require($file);
41
+        }
38 42
     }
39 43
 
40 44
 }
Please login to merge, or discard this patch.