Passed
Branch feature/remove-ocra-v1 (68bd7c)
by Pieter van der
04:02
created
library/tiqr/Tiqr/UserStorage.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -41,7 +41,7 @@
 block discarded – undo
41 41
      *
42 42
      * @throws Exception An exception if an unknown user storage is requested.
43 43
      */
44
-    public static function getStorage(string $type="file", array $options=array(), LoggerInterface $logger): Tiqr_UserStorage_Interface
44
+    public static function getStorage(string $type = "file", array $options = array(), LoggerInterface $logger): Tiqr_UserStorage_Interface
45 45
     {
46 46
         switch ($type) {
47 47
             case "file":
Please login to merge, or discard this patch.
library/tiqr/Tiqr/StateStorage.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -47,7 +47,7 @@
 block discarded – undo
47 47
      * @throws RuntimeException When the options configuration array misses a required parameter
48 48
      *
49 49
      */
50
-    public static function getStorage($type="file", $options=array(), LoggerInterface $logger)
50
+    public static function getStorage($type = "file", $options = array(), LoggerInterface $logger)
51 51
     {
52 52
         switch ($type) {
53 53
             case "file":
Please login to merge, or discard this patch.
library/tiqr/Tiqr/OcraService/Tiqr.php 1 patch
Braces   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -36,8 +36,7 @@
 block discarded – undo
36 36
         // response as the client calculated.
37 37
         try {
38 38
             $expected = OCRA::generateOCRA($this->_ocraSuite, $userSecret, "", $challenge, "", $sessionInformation, "");
39
-        }
40
-        catch (Exception $e) {
39
+        } catch (Exception $e) {
41 40
             $this->logger->warning(sprintf('Error calculating OCRA response for user "%s"', $userId), array('exception'=>$e));
42 41
             return false;
43 42
         }
Please login to merge, or discard this patch.
library/tiqr/Tiqr/OcraService/OathServiceClient.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -81,7 +81,7 @@
 block discarded – undo
81 81
                     'verifyResponse for user "%s" failed',
82 82
                     $userId
83 83
                 ),
84
-                array( 'exception' => $e)
84
+                array('exception' => $e)
85 85
             );
86 86
             return false;
87 87
         }
Please login to merge, or discard this patch.
library/tiqr/Tiqr/OcraService/Abstract.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -19,7 +19,7 @@  discard block
 block discarded – undo
19 19
 
20 20
 use Psr\Log\LoggerInterface;
21 21
 
22
-require_once(__DIR__ . '/../OATH/OCRAParser.php');
22
+require_once(__DIR__.'/../OATH/OCRAParser.php');
23 23
 
24 24
 abstract class Tiqr_OcraService_Abstract implements Tiqr_OcraService_Interface
25 25
 {
@@ -37,7 +37,7 @@  discard block
 block discarded – undo
37 37
         $this->logger = $logger;
38 38
 
39 39
         // Set the OCRA suite
40
-        $this->_ocraSuite = $config['ocra.suite'] ?? 'OCRA-1:HOTP-SHA1-6:QH10-S';   // Use tiqr server default suite
40
+        $this->_ocraSuite = $config['ocra.suite'] ?? 'OCRA-1:HOTP-SHA1-6:QH10-S'; // Use tiqr server default suite
41 41
         $this->_ocraParser = new OATH_OCRAParser($this->_ocraSuite);
42 42
     }
43 43
 
Please login to merge, or discard this patch.