Passed
Pull Request — master (#13)
by Sebastian
04:18
created
src/Mailcode/Traits/Commands/Validation/DecryptTrait.php 1 patch
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -35,7 +35,7 @@  discard block
 block discarded – undo
35 35
             ->getInfo()
36 36
             ->getTokenByParamName(DecryptInterface::PARAMETER_NAME);
37 37
 
38
-        if($token === null) {
38
+        if ($token === null) {
39 39
             return;
40 40
         }
41 41
 
@@ -45,7 +45,7 @@  discard block
 block discarded – undo
45 45
         }
46 46
 
47 47
         $this->validationResult->makeError(
48
-            t('Invalid decryption key token:') . ' ' . t('Expected a string.'),
48
+            t('Invalid decryption key token:').' '.t('Expected a string.'),
49 49
             DecryptInterface::VALIDATION_DECRYPT_CODE_WRONG_TYPE
50 50
         );
51 51
     }
@@ -58,14 +58,14 @@  discard block
 block discarded – undo
58 58
     public function getDecryptionKey() : string
59 59
     {
60 60
         $key = $this->getDecryptionKeyToken();
61
-        if($key !== null) {
61
+        if ($key !== null) {
62 62
             return $key->getText();
63 63
         }
64 64
 
65 65
         return '';
66 66
     }
67 67
 
68
-    public function enableDecryption(string $key=DecryptInterface::DEFAULT_DECRYPTION_KEY) : self
68
+    public function enableDecryption(string $key = DecryptInterface::DEFAULT_DECRYPTION_KEY) : self
69 69
     {
70 70
         $this->decryptionKeyToken = $this
71 71
             ->requireParams()
@@ -77,7 +77,7 @@  discard block
 block discarded – undo
77 77
 
78 78
     public function disableDecryption() : self
79 79
     {
80
-        if(isset($this->decryptionKeyToken)) {
80
+        if (isset($this->decryptionKeyToken)) {
81 81
             $this
82 82
                 ->requireParams()
83 83
                 ->getInfo()
Please login to merge, or discard this patch.
src/Mailcode/Interfaces/Commands/Validation/DecryptInterface.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -42,7 +42,7 @@
 block discarded – undo
42 42
      */
43 43
     public function getDecryptionKeyToken(): ?Mailcode_Parser_Statement_Tokenizer_Token_StringLiteral;
44 44
 
45
-    public function enableDecryption(string $key=DecryptInterface::DEFAULT_DECRYPTION_KEY) : self;
45
+    public function enableDecryption(string $key = DecryptInterface::DEFAULT_DECRYPTION_KEY) : self;
46 46
 
47 47
     public function disableDecryption() : self;
48 48
     public function isDecryptionEnabled() : bool;
Please login to merge, or discard this patch.