Passed
Pull Request — master (#1)
by Tim
02:21
created
src/ApiResource.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -72,7 +72,7 @@
 block discarded – undo
72 72
     {
73 73
         $url = self::endPointUrl($slug);
74 74
         if (!empty($params)) {
75
-            $url .= '?'.http_build_query($params);
75
+            $url .= '?' . http_build_query($params);
76 76
         }
77 77
 
78 78
         return $url;
Please login to merge, or discard this patch.
src/BalanceHistory.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -18,7 +18,7 @@
 block discarded – undo
18 18
     public static function ledger($params)
19 19
     {
20 20
         self::validateParams($params, true);
21
-        $url = static::classUrl().'/ledger';
21
+        $url = static::classUrl() . '/ledger';
22 22
 
23 23
         return static::staticRequest('get', $url);
24 24
     }
Please login to merge, or discard this patch.
src/Transfer.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -79,7 +79,7 @@
 block discarded – undo
79 79
     public static function resendOtp($params)
80 80
     {
81 81
         self::validateParams($params, true);
82
-        $url = static::classUrl().'/resend_otp';
82
+        $url = static::classUrl() . '/resend_otp';
83 83
 
84 84
         return static::staticRequest('POST', $url, $params);
85 85
     }
Please login to merge, or discard this patch.
src/Util/Util.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -22,8 +22,8 @@
 block discarded – undo
22 22
             self::$isMbstringAvailable = function_exists('mb_detect_encoding');
23 23
 
24 24
             if (!self::$isMbstringAvailable) {
25
-                trigger_error('It looks like the mbstring extension is not enabled. '.
26
-                    'UTF-8 strings will not properly be encoded. Ask your system '.
25
+                trigger_error('It looks like the mbstring extension is not enabled. ' .
26
+                    'UTF-8 strings will not properly be encoded. Ask your system ' .
27 27
                     'administrator to enable the mbstring extension.', E_USER_WARNING);
28 28
             }
29 29
         }
Please login to merge, or discard this patch.
src/Customer.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -27,7 +27,7 @@  discard block
 block discarded – undo
27 27
     public static function whiteOrBlackList($params)
28 28
     {
29 29
         self::validateParams($params);
30
-        $url = static::classUrl().'/set_risk_action';
30
+        $url = static::classUrl() . '/set_risk_action';
31 31
 
32 32
         return static::staticRequest('post', $url, $params);
33 33
     }
@@ -45,7 +45,7 @@  discard block
 block discarded – undo
45 45
     public static function deactivateAuthorization($params)
46 46
     {
47 47
         self::validateParams($params);
48
-        $url = static::classUrl().'/deactivate_authorization';
48
+        $url = static::classUrl() . '/deactivate_authorization';
49 49
 
50 50
         return static::staticRequest('post', $url, $params, 'arr');
51 51
     }
Please login to merge, or discard this patch.
src/ApiOperations/Request.php 1 patch
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -57,7 +57,7 @@  discard block
 block discarded – undo
57 57
      *
58 58
      * @return array|object (the JSON response as array or object)
59 59
      */
60
-    public static function staticRequest($method, $url, $params = [], $return_type = 'obj')
60
+    public static function staticRequest($method, $url, $params = [ ], $return_type = 'obj')
61 61
     {
62 62
         if ($return_type != 'arr' && $return_type != 'obj') {
63 63
             throw new InvalidArgumentException('Return type can only be obj or arr');
@@ -76,7 +76,7 @@  discard block
 block discarded – undo
76 76
      */
77 77
     protected static function setRequestOptions(): void
78 78
     {
79
-        $authBearer = 'Bearer '.Paystack::$apiKey;
79
+        $authBearer = 'Bearer ' . Paystack::$apiKey;
80 80
 
81 81
         static::$client = new Client(
82 82
             [
@@ -97,7 +97,7 @@  discard block
 block discarded – undo
97 97
      *
98 98
      * @throws IsNullException
99 99
      */
100
-    private static function setHttpResponse($method, $url, $body = []): \GuzzleHttp\Psr7\Response
100
+    private static function setHttpResponse($method, $url, $body = [ ]): \GuzzleHttp\Psr7\Response
101 101
     {
102 102
         if (is_null($method)) {
103 103
             throw new IsNullException('Empty method not allowed');
@@ -106,8 +106,8 @@  discard block
 block discarded – undo
106 106
         static::setRequestOptions();
107 107
 
108 108
         static::$response = static::$client->{strtolower($method)}(
109
-            Paystack::$apiBase.'/'.$url,
110
-            ['body' => json_encode($body)]
109
+            Paystack::$apiBase . '/' . $url,
110
+            [ 'body' => json_encode($body) ]
111 111
         );
112 112
 
113 113
         return static::$response;
@@ -130,6 +130,6 @@  discard block
 block discarded – undo
130 130
      */
131 131
     private static function getResponseData(): array
132 132
     {
133
-        return json_decode(static::$response->getBody(), true)['data'];
133
+        return json_decode(static::$response->getBody(), true)[ 'data' ];
134 134
     }
135 135
 }
Please login to merge, or discard this patch.
src/ApiOperations/All.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -14,7 +14,7 @@
 block discarded – undo
14 14
         self::validateParams($params);
15 15
         $url = static::classUrl();
16 16
         if (!empty($params)) {
17
-            $url .= '?'.http_build_query($params);
17
+            $url .= '?' . http_build_query($params);
18 18
         }
19 19
 
20 20
         return static::staticRequest('GET', $url);
Please login to merge, or discard this patch.