Passed
Pull Request — master (#43)
by
unknown
06:15
created
src/ReCaptchaBuilderV3.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -46,7 +46,7 @@  discard block
 block discarded – undo
46 46
             return '';
47 47
         }
48 48
 
49
-        $html = "<script src=\"https://".config('recaptcha.baseurl','www.google.com')."/recaptcha/api.js?render={$this->api_site_key}\"></script>";
49
+        $html = "<script src=\"https://".config('recaptcha.baseurl', 'www.google.com')."/recaptcha/api.js?render={$this->api_site_key}\"></script>";
50 50
 
51 51
         $action = Arr::get($configuration, 'action', 'homepage');
52 52
 
@@ -66,8 +66,8 @@  discard block
 block discarded – undo
66 66
 
67 67
             $validate_function = "
68 68
                 fetch('/" . config('recaptcha.default_validation_route',
69
-                    'biscolab-recaptcha/validate') . "?" . config('recaptcha.default_token_parameter_name',
70
-                    'token') . "=' + token, {
69
+                    'biscolab-recaptcha/validate')."?".config('recaptcha.default_token_parameter_name',
70
+                    'token')."=' + token, {
71 71
                     headers: {
72 72
                         \"X-Requested-With\": \"XMLHttpRequest\",
73 73
                         \"X-CSRF-TOKEN\": csrfToken.content
Please login to merge, or discard this patch.
src/ReCaptchaBuilder.php 1 patch
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -172,7 +172,7 @@  discard block
 block discarded – undo
172 172
      */
173 173
     public function setAPIURL(): ReCaptchaBuilder
174 174
     {
175
-        $this->api_url = 'https://'.config('recaptcha.baseurl','www.google.com').'/recaptcha/api/siteverify';
175
+        $this->api_url = 'https://'.config('recaptcha.baseurl', 'www.google.com').'/recaptcha/api/siteverify';
176 176
 
177 177
         return $this;
178 178
     }
@@ -189,7 +189,7 @@  discard block
 block discarded – undo
189 189
             $whitelist = explode(',', $whitelist);
190 190
         }
191 191
 
192
-        $whitelist = array_map(function ($item) {
192
+        $whitelist = array_map(function($item) {
193 193
 
194 194
             return trim($item);
195 195
         }, $whitelist);
@@ -243,11 +243,11 @@  discard block
 block discarded – undo
243 243
             $html = $this->getOnLoadCallback();
244 244
         }
245 245
 
246
-        $baseURL = config('recaptcha.baseurl','www.google.com');
246
+        $baseURL = config('recaptcha.baseurl', 'www.google.com');
247 247
 
248 248
         // Create query string
249
-        $query = ($query) ? '?' . http_build_query($query) : "";
250
-        $html .= "<script src=\"https://".$baseURL."/recaptcha/api.js" . $query . "\" async defer></script>";
249
+        $query = ($query) ? '?'.http_build_query($query) : "";
250
+        $html .= "<script src=\"https://".$baseURL."/recaptcha/api.js".$query."\" async defer></script>";
251 251
 
252 252
         return $html;
253 253
     }
@@ -281,7 +281,7 @@  discard block
 block discarded – undo
281 281
             'response' => $response,
282 282
         ]);
283 283
 
284
-        $url = $this->api_url . '?' . $params;
284
+        $url = $this->api_url.'?'.$params;
285 285
 
286 286
         if (function_exists('curl_version')) {
287 287
 
Please login to merge, or discard this patch.