Passed
Push — master ( 001a72...45db28 )
by Marco
02:10
created
src/Encrypter.php 1 patch
Braces   +3 added lines, -1 removed lines patch added patch discarded remove patch
@@ -36,7 +36,9 @@
 block discarded – undo
36 36
     public function getKey()
37 37
     {
38 38
         if ($this->key === null) {
39
-            if(! Config::get('encrypt.key')) throw new \Exception('The .env value ENCRYPT_KEY has to be set');
39
+            if(! Config::get('encrypt.key')) {
40
+                throw new \Exception('The .env value ENCRYPT_KEY has to be set');
41
+            }
40 42
             $this->key = substr(hash('sha256', Config::get('encrypt.key')), 0, 16);
41 43
         }
42 44
         return $this->key;
Please login to merge, or discard this patch.
src/DecryptModel.php 1 patch
Braces   +3 added lines, -2 removed lines patch added patch discarded remove patch
@@ -95,8 +95,9 @@
 block discarded – undo
95 95
      */
96 96
     public function guardClass($class)
97 97
     {
98
-        if (!class_exists($class))
99
-            throw new \Exception("Class {$class} does not exists");
98
+        if (!class_exists($class)) {
99
+                    throw new \Exception("Class {$class} does not exists");
100
+        }
100 101
         $model = new $class();
101 102
         $this->validateHasEncryptedColumn($model);
102 103
         return $model;
Please login to merge, or discard this patch.
src/EncryptModel.php 1 patch
Braces   +3 added lines, -2 removed lines patch added patch discarded remove patch
@@ -95,8 +95,9 @@
 block discarded – undo
95 95
      */
96 96
     public function guardClass($class)
97 97
     {
98
-        if (!class_exists($class))
99
-            throw new \Exception("Class {$class} does not exists");
98
+        if (!class_exists($class)) {
99
+                    throw new \Exception("Class {$class} does not exists");
100
+        }
100 101
         $model = new $class();
101 102
         $this->validateHasEncryptedColumn($model);
102 103
         return $model;
Please login to merge, or discard this patch.