Completed
Push — master ( e392b8...48a2ec )
by Eric
02:42
created
src/Platforms/View/Rest.php 1 patch
Braces   +2 added lines, -4 removed lines patch added patch discarded remove patch
@@ -92,8 +92,7 @@  discard block
 block discarded – undo
92 92
         {
93 93
             header('Content-Type: application/hal+xml');
94 94
             return $hal->asXml(true);
95
-        }
96
-        else
95
+        } else
97 96
         {
98 97
             header('Content-Type: application/hal+json');
99 98
             return $hal->asJson(true);
@@ -128,8 +127,7 @@  discard block
 block discarded – undo
128 127
         {
129 128
             header('Content-Type: application/problem+xml');
130 129
             return $problem->asXml(true);
131
-        }
132
-        else
130
+        } else
133 131
         {
134 132
             header('Content-Type: application/problem+json');
135 133
             return $problem->asJson(true);
Please login to merge, or discard this patch.
src/Rest/Hmac.php 1 patch
Braces   +1 added lines, -3 removed lines patch added patch discarded remove patch
@@ -79,9 +79,7 @@
 block discarded – undo
79 79
         
80 80
         try {
81 81
             return $auth->attempt($token, $this->prefix);
82
-        }
83
-        
84
-        catch (SignatureException $e) {
82
+        } catch (SignatureException $e) {
85 83
             return false;
86 84
         }
87 85
     }
Please login to merge, or discard this patch.
src/Rest/AbstractServer.php 1 patch
Braces   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -72,8 +72,7 @@
 block discarded – undo
72 72
             if(isset($headers[$version_key]) && is_numeric($headers[$version_key]) && in_array($headers[$version_key], $this->api_versions))
73 73
             {
74 74
                 $version = 'V'.str_replace('.','_',$headers[$version_key]);
75
-            }
76
-            else
75
+            } else
77 76
             {
78 77
                 $version = 'V1';
79 78
             }
Please login to merge, or discard this patch.
src/Platforms/Controllers/Rest.php 1 patch
Indentation   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -88,9 +88,9 @@
 block discarded – undo
88 88
         $hmac = $this->getRest()->getServer()->getHmac();
89 89
         $data = array_merge($this->getRequestHeaders(true), $this->getBodyData());
90 90
         $auth = $hmac->setData($data)
91
-                     ->setRoute($this->getPlatform()->getPost('api_method'))
92
-                     ->setMethod($_SERVER['REQUEST_METHOD'])
93
-                     ->auth($this->settings['api_key'], $this->settings['api_secret']);
91
+                        ->setRoute($this->getPlatform()->getPost('api_method'))
92
+                        ->setMethod($_SERVER['REQUEST_METHOD'])
93
+                        ->auth($this->settings['api_key'], $this->settings['api_secret']);
94 94
         
95 95
         if(!$auth) {
96 96
             return false;
Please login to merge, or discard this patch.