Completed
Push — master ( 791570...7aee0e )
by MeWebStudio - Muharrem
41s
created
src/Captcha.php 1 patch
Braces   +12 added lines, -4 removed lines patch added patch discarded remove patch
@@ -341,7 +341,9 @@  discard block
 block discarded – undo
341 341
         }
342 342
 
343 343
         $hash = $this->hasher->make($key);
344
-        if($this->encrypt) $hash = Crypt::encrypt($hash);
344
+        if($this->encrypt) {
345
+            $hash = Crypt::encrypt($hash);
346
+        }
345 347
         
346 348
         $this->session->put('captcha', [
347 349
             'sensitive' => $this->sensitive,
@@ -474,7 +476,9 @@  discard block
 block discarded – undo
474 476
             $value = $this->str->lower($value);
475 477
         }
476 478
 
477
-        if($encrypt) $key = Crypt::decrypt($key);
479
+        if($encrypt) {
480
+            $key = Crypt::decrypt($key);
481
+        }
478 482
         $check = $this->hasher->check($value, $key);
479 483
         // if verify pass,remove session
480 484
         if ($check) {
@@ -500,8 +504,12 @@  discard block
 block discarded – undo
500 504
 
501 505
         $this->configure($config);
502 506
 
503
-        if(!$this->sensitive) $value = $this->str->lower($value);
504
-        if($this->encrypt) $key = Crypt::decrypt($key);
507
+        if(!$this->sensitive) {
508
+            $value = $this->str->lower($value);
509
+        }
510
+        if($this->encrypt) {
511
+            $key = Crypt::decrypt($key);
512
+        }
505 513
         return $this->hasher->check($value, $key);
506 514
     }
507 515
 
Please login to merge, or discard this patch.