Test Failed
Push — main ( 74429e...c3904f )
by Dimitri
05:56 queued 03:43
created
kahlan-config.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -44,4 +44,4 @@
 block discarded – undo
44 44
     $reporters->add('coverage', $coverage);
45 45
 });
46 46
 
47
-require_once realpath(rtrim(getcwd(), '\\/ ')).DIRECTORY_SEPARATOR.'spec'.DIRECTORY_SEPARATOR.'bootstrap.php';
47
+require_once realpath(rtrim(getcwd(), '\\/ ')) . DIRECTORY_SEPARATOR . 'spec' . DIRECTORY_SEPARATOR . 'bootstrap.php';
Please login to merge, or discard this patch.
src/Parametres.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -125,7 +125,7 @@
 block discarded – undo
125 125
         $handlers = [];
126 126
 
127 127
         foreach ($this->options as $handler => $options) {
128
-            if (! empty($options['writeable'])) {
128
+            if (!empty($options['writeable'])) {
129 129
                 $handlers[] = $this->handlers[$handler];
130 130
             }
131 131
         }
Please login to merge, or discard this patch.
src/Database/Migrations/2025-01-14-142118_create_parametres_table.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -32,7 +32,7 @@
 block discarded – undo
32 32
      */
33 33
     public function up(): void
34 34
     {
35
-        $this->create($this->config->database['table'], static function (Structure $table) {
35
+        $this->create($this->config->database['table'], static function(Structure $table) {
36 36
             $table->id();
37 37
             $table->string('file');
38 38
             $table->string('key');
Please login to merge, or discard this patch.
src/Config/helpers.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -11,7 +11,7 @@
 block discarded – undo
11 11
 
12 12
 use BlitzPHP\Parametres\Parametres;
13 13
 
14
-if (! function_exists('parametre')) {
14
+if (!function_exists('parametre')) {
15 15
     /**
16 16
      * Fournit une interface pratique au service Paramètres.
17 17
      *
Please login to merge, or discard this patch.
src/Commands/ClearParametres.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -44,7 +44,7 @@
 block discarded – undo
44 44
      */
45 45
     public function execute(array $params)
46 46
     {
47
-        if (! ($this->option('yes') || $this->confirm('Cette opération supprimera tous les paramètres de la base de données. Êtes-vous sûr de vouloir continuer ?', 'n'))) {
47
+        if (!($this->option('yes') || $this->confirm('Cette opération supprimera tous les paramètres de la base de données. Êtes-vous sûr de vouloir continuer ?', 'n'))) {
48 48
             return;
49 49
         }
50 50
 
Please login to merge, or discard this patch.
src/Handlers/DatabaseHandler.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -120,7 +120,7 @@  discard block
 block discarded – undo
120 120
             ]);
121 121
         }
122 122
 
123
-        if (! $result) {
123
+        if (!$result) {
124 124
             throw new RuntimeException($this->db->error()['message'] ?? 'Erreur d\'écriture dans la base de données.');
125 125
         }
126 126
 
@@ -147,7 +147,7 @@  discard block
 block discarded – undo
147 147
 
148 148
         $result = $builder->delete();
149 149
 
150
-        if (! $result) {
150
+        if (!$result) {
151 151
             throw new RuntimeException($this->db->error()['message'] ?? 'Erreur d\'écriture dans la base de données.');
152 152
         }
153 153
 
@@ -185,7 +185,7 @@  discard block
 block discarded – undo
185 185
             $query = $this->builder()->where('context', $context);
186 186
 
187 187
             // Si le général n'a pas été hydraté, nous le ferons en même temps.
188
-            if (! in_array(null, $this->hydrated, true)) {
188
+            if (!in_array(null, $this->hydrated, true)) {
189 189
                 $this->hydrated[] = null;
190 190
                 $query->orWhereNull('context');
191 191
             }
Please login to merge, or discard this patch.
src/Handlers/BaseHandler.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -106,7 +106,7 @@  discard block
 block discarded – undo
106 106
     protected function isSerialized(mixed $data, bool $strict = true): bool
107 107
     {
108 108
         // Si ce n'est pas une chaîne, elle n'est pas sérialisée.
109
-        if (! is_string($data)) {
109
+        if (!is_string($data)) {
110 110
             return false;
111 111
         }
112 112
         $data = trim($data);
@@ -147,7 +147,7 @@  discard block
 block discarded – undo
147 147
                     if ('"' !== substr($data, -2, 1)) {
148 148
                         return false;
149 149
                     }
150
-                } elseif (! str_contains($data, '"')) {
150
+                } elseif (!str_contains($data, '"')) {
151 151
                     return false;
152 152
                 }
153 153
 
Please login to merge, or discard this patch.
src/Handlers/FileHandler.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -41,10 +41,10 @@  discard block
 block discarded – undo
41 41
         if ('' === $this->path = ($config['path'] ?? '')) {
42 42
             throw ParametresException::fileForStorageNotDefined();
43 43
         }
44
-        if (! is_dir(pathinfo($this->path, PATHINFO_DIRNAME))) {
44
+        if (!is_dir(pathinfo($this->path, PATHINFO_DIRNAME))) {
45 45
             throw ParametresException::directoryOfFileNotFound($this->path);
46 46
         }
47
-        if (! file_exists($this->path)) {
47
+        if (!file_exists($this->path)) {
48 48
             file_put_contents($this->path, '[]');
49 49
         }
50 50
     }
@@ -146,7 +146,7 @@  discard block
 block discarded – undo
146 146
             $data             = $data->whereNull('context');
147 147
         } else {
148 148
             // Si le général n'a pas été hydraté, on l'hydrate donc.
149
-            if (! in_array(null, $this->hydrated, true)) {
149
+            if (!in_array(null, $this->hydrated, true)) {
150 150
                 $this->hydrated[] = null;
151 151
             } else {
152 152
                 $data = $data->where('context', $context);
Please login to merge, or discard this patch.
src/Handlers/ArrayHandler.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -95,7 +95,7 @@
 block discarded – undo
95 95
      */
96 96
     protected function getStored(string $file, string $property, ?string $context = null): mixed
97 97
     {
98
-        if (! $this->has($file, $property, $context)) {
98
+        if (!$this->has($file, $property, $context)) {
99 99
             return null;
100 100
         }
101 101
 
Please login to merge, or discard this patch.