Test Failed
Push — master ( fc1ea0...753ee5 )
by Php Easy Api
04:07
created
src/resta/Support/ClassAliasGroup.php 2 patches
Indentation   +18 added lines, -18 removed lines patch added patch discarded remove patch
@@ -7,32 +7,32 @@
 block discarded – undo
7 7
     /**
8 8
      * @return mixed
9 9
      */
10
-   public function handle()
11
-   {
12
-       return $this->getConfigAliasGroup();
13
-   }
10
+    public function handle()
11
+    {
12
+        return $this->getConfigAliasGroup();
13
+    }
14 14
 
15 15
     /**
16 16
      * @return array
17 17
      */
18
-   public function getConfigAliasGroup()
19
-   {
20
-       $aliasGroup=app()->namespace()->config().'\AliasGroup';
21
-       if(class_exists($aliasGroup)){
22
-           return app()->resolve($aliasGroup)->handle();
23
-       }
24
-       return [];
25
-   }
18
+    public function getConfigAliasGroup()
19
+    {
20
+        $aliasGroup=app()->namespace()->config().'\AliasGroup';
21
+        if(class_exists($aliasGroup)){
22
+            return app()->resolve($aliasGroup)->handle();
23
+        }
24
+        return [];
25
+    }
26 26
 
27 27
     /**
28 28
      * @param $object
29 29
      * @param $name
30 30
      * @return void
31 31
      */
32
-   public static function setAlias($object,$name)
33
-   {
34
-       if((new $object) instanceof  $name === false){
35
-           class_alias($object,$name);
36
-       }
37
-   }
32
+    public static function setAlias($object,$name)
33
+    {
34
+        if((new $object) instanceof  $name === false){
35
+            class_alias($object,$name);
36
+        }
37
+    }
38 38
 }
39 39
\ No newline at end of file
Please login to merge, or discard this patch.
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -17,8 +17,8 @@  discard block
 block discarded – undo
17 17
      */
18 18
    public function getConfigAliasGroup()
19 19
    {
20
-       $aliasGroup=app()->namespace()->config().'\AliasGroup';
21
-       if(class_exists($aliasGroup)){
20
+       $aliasGroup = app()->namespace()->config().'\AliasGroup';
21
+       if (class_exists($aliasGroup)) {
22 22
            return app()->resolve($aliasGroup)->handle();
23 23
        }
24 24
        return [];
@@ -29,10 +29,10 @@  discard block
 block discarded – undo
29 29
      * @param $name
30 30
      * @return void
31 31
      */
32
-   public static function setAlias($object,$name)
32
+   public static function setAlias($object, $name)
33 33
    {
34
-       if((new $object) instanceof  $name === false){
35
-           class_alias($object,$name);
34
+       if ((new $object) instanceof  $name===false) {
35
+           class_alias($object, $name);
36 36
        }
37 37
    }
38 38
 }
39 39
\ No newline at end of file
Please login to merge, or discard this patch.
src/resta/Support/AppData/ServiceMiddlewareManager.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -31,7 +31,7 @@
 block discarded – undo
31 31
     public function exclude()
32 32
     {
33 33
         return [
34
-            'all'=>['hook','login','logout']
34
+            'all'=>['hook', 'login', 'logout']
35 35
         ];
36 36
     }
37 37
 }
Please login to merge, or discard this patch.
src/resta/Support/VersionManager.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -16,8 +16,8 @@  discard block
 block discarded – undo
16 16
      */
17 17
     public static function getSupportedVersions()
18 18
     {
19
-        if(self::checkSupportedVersions()){
20
-            static::$supportedVersions = array_merge(static::$supportedVersions,static::supportedVersions());
19
+        if (self::checkSupportedVersions()) {
20
+            static::$supportedVersions = array_merge(static::$supportedVersions, static::supportedVersions());
21 21
         }
22 22
         return static::$supportedVersions;
23 23
     }
@@ -29,7 +29,7 @@  discard block
 block discarded – undo
29 29
      */
30 30
     private static function checkSupportedVersions()
31 31
     {
32
-        return method_exists(static::class,'supportedVersions')
32
+        return method_exists(static::class, 'supportedVersions')
33 33
             && is_array(static::supportedVersions());
34 34
     }
35 35
 }
36 36
\ No newline at end of file
Please login to merge, or discard this patch.
src/resta/Support/Dependencies.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -7,14 +7,14 @@
 block discarded – undo
7 7
     /**
8 8
      * @var array $bootLoaders
9 9
      */
10
-    protected static $bootLoaders = ['url','logger'];
10
+    protected static $bootLoaders = ['url', 'logger'];
11 11
 
12 12
     /**
13 13
      * load bootstrapper dependencies
14 14
      *
15 15
      * @param array $loaders
16 16
      */
17
-    public static function bootLoader($loaders=array())
17
+    public static function bootLoader($loaders = array())
18 18
     {
19 19
         app()->loadIfNotExistBoot($loaders);
20 20
     }
Please login to merge, or discard this patch.
src/resta/Support/Traits/Macroable.php 2 patches
Indentation   +12 added lines, -12 removed lines patch added patch discarded remove patch
@@ -22,13 +22,13 @@  discard block
 block discarded – undo
22 22
      * @param $class
23 23
      * @return mixed
24 24
      */
25
-   public function macro($class)
26
-   {
27
-       $this->class  = $class;
28
-       $this->macro = $this;
25
+    public function macro($class)
26
+    {
27
+        $this->class  = $class;
28
+        $this->macro = $this;
29 29
 
30
-       return $this;
31
-   }
30
+        return $this;
31
+    }
32 32
 
33 33
     /**
34 34
      * get macro property
@@ -36,10 +36,10 @@  discard block
 block discarded – undo
36 36
      * @param $name
37 37
      * @return mixed
38 38
      */
39
-   public function __get($name)
40
-   {
41
-       return ClosureDispatcher::bind($this->class)->call(function() use($name){
42
-          return $this->{$name};
43
-       });
44
-   }
39
+    public function __get($name)
40
+    {
41
+        return ClosureDispatcher::bind($this->class)->call(function() use($name){
42
+            return $this->{$name};
43
+        });
44
+    }
45 45
 }
46 46
\ No newline at end of file
Please login to merge, or discard this patch.
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -24,7 +24,7 @@
 block discarded – undo
24 24
      */
25 25
    public function macro($class)
26 26
    {
27
-       $this->class  = $class;
27
+       $this->class = $class;
28 28
        $this->macro = $this;
29 29
 
30 30
        return $this;
Please login to merge, or discard this patch.
src/resta/Support/YamlManager.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -36,10 +36,10 @@
 block discarded – undo
36 36
         return $this->yaml;
37 37
     }
38 38
 
39
-    public function set($data=array())
39
+    public function set($data = array())
40 40
     {
41 41
         //we merge the data in yaml with new data.
42
-        $newYamlData = array_merge($this->yaml,$data);
42
+        $newYamlData = array_merge($this->yaml, $data);
43 43
 
44 44
         //we dump new data.
45 45
         $yaml = Yaml::dump($newYamlData);
Please login to merge, or discard this patch.
src/resta/Support/ClosureDispatcher.php 2 patches
Braces   +3 added lines, -2 removed lines patch added patch discarded remove patch
@@ -33,8 +33,9 @@
 block discarded – undo
33 33
      */
34 34
     public function call(\Closure $closure)
35 35
     {
36
-        if(!is_null($this->bind))
37
-            $closure = \Closure::bind($closure, $this->bind, $this->bind);
36
+        if(!is_null($this->bind)) {
37
+                    $closure = \Closure::bind($closure, $this->bind, $this->bind);
38
+        }
38 39
         return $closure();
39 40
     }
40 41
 }
41 42
\ No newline at end of file
Please login to merge, or discard this patch.
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -35,7 +35,7 @@
 block discarded – undo
35 35
      */
36 36
     public function call(\Closure $closure)
37 37
     {
38
-        if(!is_null($this->bind))
38
+        if (!is_null($this->bind))
39 39
             $closure = \Closure::bind($closure, $this->bind, $this->bind);
40 40
         return $closure();
41 41
     }
Please login to merge, or discard this patch.
bootstrap.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -1,7 +1,7 @@
 block discarded – undo
1 1
 <?php
2 2
 
3 3
 //root definer: application root path
4
-define("root",str_replace("\\","/",realpath(__DIR__.'/')));
4
+define("root", str_replace("\\", "/", realpath(__DIR__.'/')));
5 5
 
6 6
 /**
7 7
  * resta system composer vendor autoload.
Please login to merge, or discard this patch.
src/resta/Request/RequestHttpManager.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -33,9 +33,9 @@
 block discarded – undo
33 33
     {
34 34
         $inputs = $this->app->get($this->method);
35 35
 
36
-        $content = json_decode($this->app['request']->getContent(),1);
36
+        $content = json_decode($this->app['request']->getContent(), 1);
37 37
 
38
-        if(is_array($inputs) && count($inputs)){
38
+        if (is_array($inputs) && count($inputs)) {
39 39
             return $inputs;
40 40
         }
41 41
 
Please login to merge, or discard this patch.