Passed
Push — main ( 6ce554...c04f85 )
by Dimitri
03:29
created
src/Http/Middleware.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -65,7 +65,7 @@
 block discarded – undo
65 65
      */
66 66
     public function add($middlewares, array $options = []): self
67 67
     {
68
-        if (! is_array($middlewares)) {
68
+        if (!is_array($middlewares)) {
69 69
             $middlewares = [$middlewares];
70 70
         }
71 71
 
Please login to merge, or discard this patch.
src/Config/Database.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -57,11 +57,11 @@  discard block
 block discarded – undo
57 57
             $group = on_test() ? 'test' : (on_prod() ? 'production' : 'development');
58 58
         }
59 59
 
60
-        if (! isset($config[$group]) && strpos($group, 'custom-') === false) {
60
+        if (!isset($config[$group]) && strpos($group, 'custom-') === false) {
61 61
             $group = 'default';
62 62
         }
63 63
 
64
-        if (is_string($group) && ! isset($config[$group]) && strpos($group, 'custom-') !== 0) {
64
+        if (is_string($group) && !isset($config[$group]) && strpos($group, 'custom-') !== 0) {
65 65
             throw new InvalidArgumentException($group . ' is not a valid database connection group.');
66 66
         }
67 67
 
@@ -71,7 +71,7 @@  discard block
 block discarded – undo
71 71
 
72 72
         $config = $config[$group];
73 73
 
74
-        if (str_contains($config['driver'], 'sqlite') && $config['database'] !== ':memory:' && ! str_contains($config['database'], DS)) {
74
+        if (str_contains($config['driver'], 'sqlite') && $config['database'] !== ':memory:' && !str_contains($config['database'], DS)) {
75 75
             $config['database'] = APP_STORAGE_PATH . $config['database'];
76 76
         }
77 77
 
@@ -93,7 +93,7 @@  discard block
 block discarded – undo
93 93
 
94 94
         // Si le package "blitz-php/database" n'existe pas on renvoi une fake connection
95 95
         // Ceci est utile juste pour eviter le bug avec le service provider
96
-        if (! class_exists(Db::class)) {
96
+        if (!class_exists(Db::class)) {
97 97
             return static::createMockConnection();
98 98
         }
99 99
 
Please login to merge, or discard this patch.
src/Http/Concerns/InteractsWithContentTypes.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -31,7 +31,7 @@
 block discarded – undo
31 31
      */
32 32
     public function expectsJson(): bool
33 33
     {
34
-        return ($this->ajax() && ! $this->pjax() && $this->acceptsAnyContentType()) || $this->wantsJson();
34
+        return ($this->ajax() && !$this->pjax() && $this->acceptsAnyContentType()) || $this->wantsJson();
35 35
     }
36 36
 
37 37
     /**
Please login to merge, or discard this patch.
src/Http/Concerns/ResponseTrait.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -98,7 +98,7 @@
 block discarded – undo
98 98
             return $this->withFile($filepath, ['download' => true, 'name' => $filename]);
99 99
         }
100 100
 
101
-        if (! empty($data)) {
101
+        if (!empty($data)) {
102 102
             return $this->withStringBody($data)
103 103
                 ->withType(pathinfo($filename, PATHINFO_EXTENSION))
104 104
                 ->withDownload($filename);
Please login to merge, or discard this patch.
src/Http/Concerns/InteractsWithInput.php 1 patch
Spacing   +9 added lines, -9 removed lines patch added patch discarded remove patch
@@ -87,7 +87,7 @@  discard block
 block discarded – undo
87 87
         $input = $this->all();
88 88
 
89 89
         foreach ($keys as $value) {
90
-            if (! Arr::has($input, $value)) {
90
+            if (!Arr::has($input, $value)) {
91 91
                 return false;
92 92
             }
93 93
         }
@@ -149,7 +149,7 @@  discard block
 block discarded – undo
149 149
         $keys = is_array($key) ? $key : func_get_args();
150 150
 
151 151
         foreach ($keys as $value) {
152
-            if (! $this->isEmptyString($value)) {
152
+            if (!$this->isEmptyString($value)) {
153 153
                 return false;
154 154
             }
155 155
         }
@@ -198,7 +198,7 @@  discard block
 block discarded – undo
198 198
     {
199 199
         $keys = is_array($key) ? $key : func_get_args();
200 200
 
201
-        return ! $this->has($keys);
201
+        return !$this->has($keys);
202 202
     }
203 203
 
204 204
     /**
@@ -226,7 +226,7 @@  discard block
 block discarded – undo
226 226
     {
227 227
         $value = $this->input($key);
228 228
 
229
-        return ! is_bool($value) && ! is_array($value) && trim((string) $value) === '';
229
+        return !is_bool($value) && !is_array($value) && trim((string) $value) === '';
230 230
     }
231 231
 
232 232
     /**
@@ -246,7 +246,7 @@  discard block
 block discarded – undo
246 246
     {
247 247
         $input = array_replace_recursive($this->data(), $this->allFiles());
248 248
 
249
-        if (! $keys) {
249
+        if (!$keys) {
250 250
             return $input;
251 251
         }
252 252
 
@@ -341,9 +341,9 @@  discard block
 block discarded – undo
341 341
     public function enum(string $key, $enumClass)
342 342
     {
343 343
         if ($this->isNotFilled($key)
344
-            || ! function_exists('enum_exists')
345
-            || ! enum_exists($enumClass)
346
-            || ! method_exists($enumClass, 'tryFrom')) {
344
+            || !function_exists('enum_exists')
345
+            || !enum_exists($enumClass)
346
+            || !method_exists($enumClass, 'tryFrom')) {
347 347
             return null;
348 348
         }
349 349
 
@@ -457,7 +457,7 @@  discard block
 block discarded – undo
457 457
      */
458 458
     public function hasFile(string $key): bool
459 459
     {
460
-        if (! is_array($files = $this->file($key))) {
460
+        if (!is_array($files = $this->file($key))) {
461 461
             $files = [$files];
462 462
         }
463 463
 
Please login to merge, or discard this patch.
src/Http/Request.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -96,7 +96,7 @@
 block discarded – undo
96 96
      */
97 97
     public function fullUrl(): string
98 98
     {
99
-        if (! empty($query = $this->getEnv('QUERY_STRING'))) {
99
+        if (!empty($query = $this->getEnv('QUERY_STRING'))) {
100 100
             return $this->url() . '?' . $query;
101 101
         }
102 102
 
Please login to merge, or discard this patch.
src/Http/Redirection.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -50,7 +50,7 @@  discard block
 block discarded – undo
50 50
     {
51 51
         $route = Services::routes()->reverseRoute($route, ...$params);
52 52
 
53
-        if (! $route) {
53
+        if (!$route) {
54 54
             throw HttpException::invalidRedirectRoute($route);
55 55
         }
56 56
 
@@ -81,7 +81,7 @@  discard block
 block discarded – undo
81 81
             $errors = [$errors];
82 82
         }
83 83
 
84
-        if (! empty($errors)) {
84
+        if (!empty($errors)) {
85 85
             $session = Services::session();
86 86
             $_errors = $session->getFlashdata('errors') ?? [];
87 87
             $session->setFlashdata(
Please login to merge, or discard this patch.
src/Models/BaseModel.php 1 patch
Spacing   +11 added lines, -11 removed lines patch added patch discarded remove patch
@@ -232,7 +232,7 @@  discard block
 block discarded – undo
232 232
                 return $this->db->table($table);
233 233
             }
234 234
 
235
-            if (empty($builderTable) && ! empty($this->table)) {
235
+            if (empty($builderTable) && !empty($this->table)) {
236 236
                 $this->builder = $this->builder->table($this->table);
237 237
             }
238 238
 
@@ -240,7 +240,7 @@  discard block
 block discarded – undo
240 240
         }
241 241
 
242 242
         // S'assurer qu'on a une bonne connxion a la base de donnees
243
-        if (! $this->db instanceof ConnectionInterface) {
243
+        if (!$this->db instanceof ConnectionInterface) {
244 244
             $this->db = Database::connect($this->group);
245 245
         }
246 246
 
@@ -272,7 +272,7 @@  discard block
 block discarded – undo
272 272
      */
273 273
     public function create(array|object|null $data = null, bool $returnID = true)
274 274
     {
275
-        if (! empty($this->tempData['data'])) {
275
+        if (!empty($this->tempData['data'])) {
276 276
             if (empty($data)) {
277 277
                 $data = $this->tempData['data'];
278 278
             } else {
@@ -315,7 +315,7 @@  discard block
 block discarded – undo
315 315
     {
316 316
         $id = $id ?: $this->primaryKeyValue;
317 317
 
318
-        if (! empty($this->tempData['data'])) {
318
+        if (!empty($this->tempData['data'])) {
319 319
             if (empty($data)) {
320 320
                 $data = $this->tempData['data'];
321 321
             } else {
@@ -433,7 +433,7 @@  discard block
 block discarded – undo
433 433
             return $data->{$this->primaryKey};
434 434
         }
435 435
 
436
-        if (is_array($data) && ! empty($data[$this->primaryKey])) {
436
+        if (is_array($data) && !empty($data[$this->primaryKey])) {
437 437
             return $data[$this->primaryKey];
438 438
         }
439 439
 
@@ -446,7 +446,7 @@  discard block
 block discarded – undo
446 446
      */
447 447
     protected function shouldUpdate(array|object $data): bool
448 448
     {
449
-        return ! empty($this->idValue($data));
449
+        return !empty($this->idValue($data));
450 450
     }
451 451
 
452 452
     /**
@@ -464,7 +464,7 @@  discard block
 block discarded – undo
464 464
 
465 465
         // Convertissez toutes les instances de Date en $dateFormat approprié
466 466
         if ($properties) {
467
-            $properties = array_map(function ($value) {
467
+            $properties = array_map(function($value) {
468 468
                 if ($value instanceof Date) {
469 469
                     return $this->timeToDate($value);
470 470
                 }
@@ -492,7 +492,7 @@  discard block
 block discarded – undo
492 492
             $properties = $data->toArray();
493 493
         } else {
494 494
             $mirror = new ReflectionClass($data);
495
-            $props  = $mirror->getProperties(ReflectionProperty::IS_PUBLIC | ReflectionProperty::IS_PROTECTED);
495
+            $props  = $mirror->getProperties(ReflectionProperty::IS_PUBLIC|ReflectionProperty::IS_PROTECTED);
496 496
 
497 497
             $properties = [];
498 498
 
@@ -546,7 +546,7 @@  discard block
 block discarded – undo
546 546
      */
547 547
     protected function transformDataToArray(array|object|null $data, string $type): array
548 548
     {
549
-        if (! in_array($type, ['insert', 'update'], true)) {
549
+        if (!in_array($type, ['insert', 'update'], true)) {
550 550
             throw new InvalidArgumentException(sprintf('Invalid type "%s" used upon transforming data to array.', $type));
551 551
         }
552 552
 
@@ -556,7 +556,7 @@  discard block
 block discarded – undo
556 556
 
557 557
         // Si $data utilise une classe personnalisée avec des propriétés publiques ou protégées représentant
558 558
         // les éléments de la collection, nous devons les saisir sous forme de tableau.
559
-        if (is_object($data) && ! $data instanceof stdClass) {
559
+        if (is_object($data) && !$data instanceof stdClass) {
560 560
             $data = $this->objectToArray($data, $type === 'update', true);
561 561
         }
562 562
 
@@ -567,7 +567,7 @@  discard block
 block discarded – undo
567 567
         }
568 568
 
569 569
         // S'il est toujours vide ici, cela signifie que $data n'a pas changé ou est un objet vide
570
-        if (! $this->allowEmptyInserts && empty($data)) {
570
+        if (!$this->allowEmptyInserts && empty($data)) {
571 571
             throw DataException::emptyDataset($type);
572 572
         }
573 573
 
Please login to merge, or discard this patch.
src/Helpers/common.php 1 patch
Spacing   +62 added lines, -62 removed lines patch added patch discarded remove patch
@@ -25,7 +25,7 @@  discard block
 block discarded – undo
25 25
 
26 26
 // ================================= FONCTIONS D'ACCESSIBILITE ================================= //
27 27
 
28
-if (! function_exists('env')) {
28
+if (!function_exists('env')) {
29 29
     /**
30 30
      * Obtient une variable d'environnement à partir des sources disponibles et fournit une émulation
31 31
      * pour les variables d'environnement non prises en charge ou incohérentes
@@ -41,7 +41,7 @@  discard block
 block discarded – undo
41 41
     }
42 42
 }
43 43
 
44
-if (! function_exists('helper')) {
44
+if (!function_exists('helper')) {
45 45
     /**
46 46
      * Charge un fichier d'aide en mémoire. Prend en charge les assistants d'espace de noms,
47 47
      * à la fois dans et hors du répertoire 'helpers' d'un répertoire à espace de noms.
@@ -59,7 +59,7 @@  discard block
 block discarded – undo
59 59
     }
60 60
 }
61 61
 
62
-if (! function_exists('model')) {
62
+if (!function_exists('model')) {
63 63
     /**
64 64
      * Simple maniere d'obtenir un modele.
65 65
      *
@@ -69,13 +69,13 @@  discard block
 block discarded – undo
69 69
      *
70 70
      * @return T
71 71
      */
72
-    function model(string|array $name, ?ConnectionInterface &$conn = null)
72
+    function model(string|array $name, ?ConnectionInterface&$conn = null)
73 73
     {
74 74
         return Load::model($name, $conn);
75 75
     }
76 76
 }
77 77
 
78
-if (! function_exists('service')) {
78
+if (!function_exists('service')) {
79 79
     /**
80 80
      * Permet un accès plus propre au fichier de configuration des services.
81 81
      * Renvoie toujours une instance SHARED de la classe, donc
@@ -92,7 +92,7 @@  discard block
 block discarded – undo
92 92
     }
93 93
 }
94 94
 
95
-if (! function_exists('single_service')) {
95
+if (!function_exists('single_service')) {
96 96
     /**
97 97
      * Autoriser l'accès propre à un service.
98 98
      * Renvoie toujours une nouvelle instance de la classe.
@@ -106,7 +106,7 @@  discard block
 block discarded – undo
106 106
     }
107 107
 }
108 108
 
109
-if (! function_exists('show404')) {
109
+if (!function_exists('show404')) {
110 110
     /**
111 111
      * Afficher une page 404 introuvable dans le navigateur
112 112
      */
@@ -116,7 +116,7 @@  discard block
 block discarded – undo
116 116
     }
117 117
 }
118 118
 
119
-if (! function_exists('config')) {
119
+if (!function_exists('config')) {
120 120
     /**
121 121
      * GET/SET App config
122 122
      *
@@ -126,7 +126,7 @@  discard block
 block discarded – undo
126 126
      */
127 127
     function config(string $config, $value = null, bool $force_set = false)
128 128
     {
129
-        if (! empty($value) || (empty($value) && true === $force_set)) {
129
+        if (!empty($value) || (empty($value) && true === $force_set)) {
130 130
             Config::set($config, $value);
131 131
         }
132 132
 
@@ -136,7 +136,7 @@  discard block
 block discarded – undo
136 136
 
137 137
 // =========================== FONCTIONS DE PREVENTION D'ATTAQUE =========================== //
138 138
 
139
-if (! function_exists('esc')) {
139
+if (!function_exists('esc')) {
140 140
     /**
141 141
      * Effectue un simple échappement automatique des données pour des raisons de sécurité.
142 142
      * Pourrait envisager de rendre cela plus complexe à une date ultérieure.
@@ -163,7 +163,7 @@  discard block
 block discarded – undo
163 163
     }
164 164
 }
165 165
 
166
-if (! function_exists('h')) {
166
+if (!function_exists('h')) {
167 167
     /**
168 168
      * Méthode pratique pour htmlspecialchars.
169 169
      *
@@ -182,7 +182,7 @@  discard block
 block discarded – undo
182 182
     }
183 183
 }
184 184
 
185
-if (! function_exists('purify')) {
185
+if (!function_exists('purify')) {
186 186
     /**
187 187
      * Purifiez l'entrée à l'aide de la classe autonome HTMLPurifier.
188 188
      * Utilisez facilement plusieurs configurations de purificateur.
@@ -200,7 +200,7 @@  discard block
 block discarded – undo
200 200
     }
201 201
 }
202 202
 
203
-if (! function_exists('remove_invisible_characters')) {
203
+if (!function_exists('remove_invisible_characters')) {
204 204
     /**
205 205
      * Supprimer les caractères invisibles
206 206
      *
@@ -213,7 +213,7 @@  discard block
 block discarded – undo
213 213
     }
214 214
 }
215 215
 
216
-if (! function_exists('stringify_attributes')) {
216
+if (!function_exists('stringify_attributes')) {
217 217
     /**
218 218
      * Chaîner les attributs à utiliser dans les balises HTML.
219 219
      *
@@ -227,7 +227,7 @@  discard block
 block discarded – undo
227 227
 
228 228
 // ================================= FONCTIONS D'ENVIRONNEMENT D'EXECUTION ================================= //
229 229
 
230
-if (! function_exists('on_dev')) {
230
+if (!function_exists('on_dev')) {
231 231
     /**
232 232
      * Testez pour voir si nous sommes dans un environnement de développement.
233 233
      */
@@ -243,7 +243,7 @@  discard block
 block discarded – undo
243 243
     }
244 244
 }
245 245
 
246
-if (! function_exists('on_prod')) {
246
+if (!function_exists('on_prod')) {
247 247
     /**
248 248
      * Testez pour voir si nous sommes dans un environnement de production.
249 249
      */
@@ -259,7 +259,7 @@  discard block
 block discarded – undo
259 259
     }
260 260
 }
261 261
 
262
-if (! function_exists('on_test')) {
262
+if (!function_exists('on_test')) {
263 263
     /**
264 264
      * Testez pour voir si nous sommes dans un environnement de test
265 265
      */
@@ -271,7 +271,7 @@  discard block
 block discarded – undo
271 271
     }
272 272
 }
273 273
 
274
-if (! function_exists('is_cli')) {
274
+if (!function_exists('is_cli')) {
275 275
     /**
276 276
      * Testez pour voir si une demande a été faite à partir de la ligne de commande.
277 277
      */
@@ -281,7 +281,7 @@  discard block
 block discarded – undo
281 281
     }
282 282
 }
283 283
 
284
-if (! function_exists('is_php')) {
284
+if (!function_exists('is_php')) {
285 285
     /**
286 286
      * Détermine si la version actuelle de PHP est égale ou supérieure à la valeur fournie.
287 287
      */
@@ -291,7 +291,7 @@  discard block
 block discarded – undo
291 291
     }
292 292
 }
293 293
 
294
-if (! function_exists('is_windows')) {
294
+if (!function_exists('is_windows')) {
295 295
     /**
296 296
      * Déterminez si l'environnement actuel est basé sur Windows.
297 297
      */
@@ -301,7 +301,7 @@  discard block
 block discarded – undo
301 301
     }
302 302
 }
303 303
 
304
-if (! function_exists('is_https')) {
304
+if (!function_exists('is_https')) {
305 305
     /**
306 306
      * Determines if the application is accessed via an encrypted * (HTTPS) connection.
307 307
      */
@@ -311,7 +311,7 @@  discard block
 block discarded – undo
311 311
     }
312 312
 }
313 313
 
314
-if (! function_exists('is_localfile')) {
314
+if (!function_exists('is_localfile')) {
315 315
     /**
316 316
      * Vérifiez si le fichier auquel vous souhaitez accéder est un fichier local de votre application ou non
317 317
      */
@@ -321,11 +321,11 @@  discard block
 block discarded – undo
321 321
             return true;
322 322
         }
323 323
 
324
-        return ! preg_match('#^(https?://)#i', $name);
324
+        return !preg_match('#^(https?://)#i', $name);
325 325
     }
326 326
 }
327 327
 
328
-if (! function_exists('is_online')) {
328
+if (!function_exists('is_online')) {
329 329
     /**
330 330
      * Tester si l'application s'exécute en local ou en ligne.
331 331
      */
@@ -335,7 +335,7 @@  discard block
 block discarded – undo
335 335
     }
336 336
 }
337 337
 
338
-if (! function_exists('is_connected')) {
338
+if (!function_exists('is_connected')) {
339 339
     /**
340 340
      * Verifie si l'utilisateur a une connexion internet active.
341 341
      */
@@ -345,7 +345,7 @@  discard block
 block discarded – undo
345 345
     }
346 346
 }
347 347
 
348
-if (! function_exists('is_ajax_request')) {
348
+if (!function_exists('is_ajax_request')) {
349 349
     /**
350 350
      * Testez pour voir si une requête contient l'en-tête HTTP_X_REQUESTED_WITH.
351 351
      */
@@ -355,7 +355,7 @@  discard block
 block discarded – undo
355 355
     }
356 356
 }
357 357
 
358
-if (! function_exists('redirection')) {
358
+if (!function_exists('redirection')) {
359 359
     /**
360 360
      * Redirige l'utilisateur
361 361
      */
@@ -369,7 +369,7 @@  discard block
 block discarded – undo
369 369
     }
370 370
 }
371 371
 
372
-if (! function_exists('redirect')) {
372
+if (!function_exists('redirect')) {
373 373
     /**
374 374
      * Méthode pratique qui fonctionne avec la $request globale actuelle et
375 375
      * l'instance $router à rediriger à l'aide de routes nommées et le routage inversé
@@ -383,7 +383,7 @@  discard block
 block discarded – undo
383 383
     {
384 384
         $redirection = Services::redirection();
385 385
 
386
-        if (! empty($uri)) {
386
+        if (!empty($uri)) {
387 387
             return $redirection->route($uri);
388 388
         }
389 389
 
@@ -391,7 +391,7 @@  discard block
 block discarded – undo
391 391
     }
392 392
 }
393 393
 
394
-if (! function_exists('link_to')) {
394
+if (!function_exists('link_to')) {
395 395
     /**
396 396
      * Étant donné une chaîne de contrôleur/méthode et tous les paramètres,
397 397
      * tentera de créer l'URL relative à la route correspondante.
@@ -407,7 +407,7 @@  discard block
 block discarded – undo
407 407
     }
408 408
 }
409 409
 
410
-if (! function_exists('clean_path')) {
410
+if (!function_exists('clean_path')) {
411 411
     /**
412 412
      * Une méthode pratique pour nettoyer les chemins pour
413 413
      * une sortie plus belle. Utile pour les exceptions
@@ -436,7 +436,7 @@  discard block
 block discarded – undo
436 436
     }
437 437
 }
438 438
 
439
-if (! function_exists('old')) {
439
+if (!function_exists('old')) {
440 440
     /**
441 441
      * Fournit l'accès à "entrée ancienne" qui a été définie dans la session lors d'un redirect()-withInput().
442 442
      *
@@ -448,7 +448,7 @@  discard block
 block discarded – undo
448 448
     function old(string $key, ?string $default = null, $escape = 'html')
449 449
     {
450 450
         // Assurez-vous de charger la session
451
-        if (session_status() === PHP_SESSION_NONE && ! on_test()) {
451
+        if (session_status() === PHP_SESSION_NONE && !on_test()) {
452 452
             session(); // @codeCoverageIgnore
453 453
         }
454 454
 
@@ -463,7 +463,7 @@  discard block
 block discarded – undo
463 463
 
464 464
 // ================================= FONCTIONS DE DEBOGAGE ================================= //
465 465
 
466
-if (! function_exists('dd')) {
466
+if (!function_exists('dd')) {
467 467
     /**
468 468
      * Prints a Kint debug report and exits.
469 469
      *
@@ -482,7 +482,7 @@  discard block
 block discarded – undo
482 482
     }
483 483
 }
484 484
 
485
-if (! function_exists('dump')) {
485
+if (!function_exists('dump')) {
486 486
     /**
487 487
      * Prints a Kint debug report and exits.
488 488
      *
@@ -499,7 +499,7 @@  discard block
 block discarded – undo
499 499
     }
500 500
 }
501 501
 
502
-if (! function_exists('deprecationWarning')) {
502
+if (!function_exists('deprecationWarning')) {
503 503
     /**
504 504
      * Méthode d'assistance pour générer des avertissements d'obsolescence
505 505
      *
@@ -515,7 +515,7 @@  discard block
 block discarded – undo
515 515
     }
516 516
 }
517 517
 
518
-if (! function_exists('logger')) {
518
+if (!function_exists('logger')) {
519 519
     /**
520 520
      * A convenience/compatibility method for logging events through
521 521
      * the Log system.
@@ -538,7 +538,7 @@  discard block
 block discarded – undo
538 538
     {
539 539
         $logger = Services::logger();
540 540
 
541
-        if (! empty($level) && ! empty($message)) {
541
+        if (!empty($level) && !empty($message)) {
542 542
             return $logger->log($level, $message, $context);
543 543
         }
544 544
 
@@ -546,7 +546,7 @@  discard block
 block discarded – undo
546 546
     }
547 547
 }
548 548
 
549
-if (! function_exists('cache')) {
549
+if (!function_exists('cache')) {
550 550
     /**
551 551
      * Une méthode pratique qui donne accès au cache
552 552
      * objet. Si aucun paramètre n'est fourni, renverra l'objet,
@@ -576,7 +576,7 @@  discard block
 block discarded – undo
576 576
     }
577 577
 }
578 578
 
579
-if (! function_exists('session')) {
579
+if (!function_exists('session')) {
580 580
     /**
581 581
      * Une méthode pratique pour accéder à l'instance de session, ou un élément qui a été défini dans la session.
582 582
      *
@@ -599,7 +599,7 @@  discard block
 block discarded – undo
599 599
     }
600 600
 }
601 601
 
602
-if (! function_exists('pr')) {
602
+if (!function_exists('pr')) {
603 603
     /**
604 604
      * print_r() convenience function.
605 605
      *
@@ -621,7 +621,7 @@  discard block
 block discarded – undo
621 621
     }
622 622
 }
623 623
 
624
-if (! function_exists('pj')) {
624
+if (!function_exists('pj')) {
625 625
     /**
626 626
      * json pretty print convenience function.
627 627
      *
@@ -642,7 +642,7 @@  discard block
 block discarded – undo
642 642
     }
643 643
 }
644 644
 
645
-if (! function_exists('trigger_warning')) {
645
+if (!function_exists('trigger_warning')) {
646 646
     /**
647 647
      * Déclenche un E_USER_WARNING.
648 648
      */
@@ -652,7 +652,7 @@  discard block
 block discarded – undo
652 652
     }
653 653
 }
654 654
 
655
-if (! function_exists('vd')) {
655
+if (!function_exists('vd')) {
656 656
     /**
657 657
      * Shortcut to ref, HTML mode
658 658
      *
@@ -664,7 +664,7 @@  discard block
 block discarded – undo
664 664
     }
665 665
 }
666 666
 
667
-if (! function_exists('vdt')) {
667
+if (!function_exists('vdt')) {
668 668
     /**
669 669
      * Shortcut to ref, plain text mode
670 670
      *
@@ -678,7 +678,7 @@  discard block
 block discarded – undo
678 678
 
679 679
 // ================================= FONCTIONS DIVERSES ================================= //
680 680
 
681
-if (! function_exists('force_https')) {
681
+if (!function_exists('force_https')) {
682 682
     /**
683 683
      * Utilisé pour forcer l'accès à une page via HTTPS.
684 684
      * Utilise une redirection standard, plus définira l'en-tête HSTS
@@ -736,7 +736,7 @@  discard block
 block discarded – undo
736 736
     }
737 737
 }
738 738
 
739
-if (! function_exists('getTypeName')) {
739
+if (!function_exists('getTypeName')) {
740 740
     /**
741 741
      * Renvoie la classe d'objets ou le type var de ce n'est pas un objet
742 742
      *
@@ -750,7 +750,7 @@  discard block
 block discarded – undo
750 750
     }
751 751
 }
752 752
 
753
-if (! function_exists('ip_address')) {
753
+if (!function_exists('ip_address')) {
754 754
     /**
755 755
      * Renvoie l'adresse IP de l'utilisateur actuel
756 756
      */
@@ -760,7 +760,7 @@  discard block
 block discarded – undo
760 760
     }
761 761
 }
762 762
 
763
-if (! function_exists('is_really_writable')) {
763
+if (!function_exists('is_really_writable')) {
764 764
     /**
765 765
      * Tests d'inscriptibilité des fichiers
766 766
      */
@@ -770,7 +770,7 @@  discard block
 block discarded – undo
770 770
     }
771 771
 }
772 772
 
773
-if (! function_exists('lang')) {
773
+if (!function_exists('lang')) {
774 774
     /**
775 775
      * Une méthode pratique pour traduire une chaîne ou un tableau d'entrées et formater
776 776
      * le résultat avec le MessageFormatter de l'extension intl.
@@ -781,7 +781,7 @@  discard block
 block discarded – undo
781 781
     }
782 782
 }
783 783
 
784
-if (! function_exists('namespace_split')) {
784
+if (!function_exists('namespace_split')) {
785 785
     /**
786 786
      * Séparez l'espace de noms du nom de classe.
787 787
      *
@@ -802,7 +802,7 @@  discard block
 block discarded – undo
802 802
     }
803 803
 }
804 804
 
805
-if (! function_exists('view_exist')) {
805
+if (!function_exists('view_exist')) {
806 806
     /**
807 807
      * Verifie si un fichier de vue existe. Utile pour limiter les failles include
808 808
      */
@@ -816,7 +816,7 @@  discard block
 block discarded – undo
816 816
     }
817 817
 }
818 818
 
819
-if (! function_exists('view')) {
819
+if (!function_exists('view')) {
820 820
     /**
821 821
      * Charge une vue
822 822
      *
@@ -832,7 +832,7 @@  discard block
 block discarded – undo
832 832
     }
833 833
 }
834 834
 
835
-if (! function_exists('flash')) {
835
+if (!function_exists('flash')) {
836 836
     /**
837 837
      * Fournisseur d'acces rapide a la classe PHP Flash
838 838
      *
@@ -864,7 +864,7 @@  discard block
 block discarded – undo
864 864
     }*/
865 865
 }
866 866
 
867
-if (! function_exists('geo_ip')) {
867
+if (!function_exists('geo_ip')) {
868 868
     /**
869 869
      * Recuperation des coordonnees (pays, ville, etc) d'un utilisateur en fonction de son ip
870 870
      */
@@ -874,7 +874,7 @@  discard block
 block discarded – undo
874 874
     }
875 875
 }
876 876
 
877
-if (! function_exists('to_stream')) {
877
+if (!function_exists('to_stream')) {
878 878
     /**
879 879
      * Créez un nouveau flux basé sur le type d'entrée.
880 880
      *
@@ -897,7 +897,7 @@  discard block
 block discarded – undo
897 897
     }
898 898
 }
899 899
 
900
-if (! function_exists('value')) {
900
+if (!function_exists('value')) {
901 901
     /**
902 902
      * Renvoie la valeur par défaut de la valeur donnée.
903 903
      */
@@ -907,7 +907,7 @@  discard block
 block discarded – undo
907 907
     }
908 908
 }
909 909
 
910
-if (! function_exists('collect')) {
910
+if (!function_exists('collect')) {
911 911
     /**
912 912
      * Créez une collection à partir de la valeur donnée.
913 913
      */
@@ -917,7 +917,7 @@  discard block
 block discarded – undo
917 917
     }
918 918
 }
919 919
 
920
-if (! function_exists('with')) {
920
+if (!function_exists('with')) {
921 921
     /**
922 922
      * Renvoie la valeur donnée, éventuellement transmise via le rappel donné.
923 923
      *
@@ -929,7 +929,7 @@  discard block
 block discarded – undo
929 929
     }
930 930
 }
931 931
 
932
-if (! function_exists('tap')) {
932
+if (!function_exists('tap')) {
933 933
     /**
934 934
      * Appelez la Closure donnée avec cette instance puis renvoyez l'instance.
935 935
      */
@@ -939,7 +939,7 @@  discard block
 block discarded – undo
939 939
     }
940 940
 }
941 941
 
942
-if (! function_exists('last')) {
942
+if (!function_exists('last')) {
943 943
     /**
944 944
      * Recupere le dernier element d'un tableau
945 945
      */
@@ -949,7 +949,7 @@  discard block
 block discarded – undo
949 949
     }
950 950
 }
951 951
 
952
-if (! function_exists('invade')) {
952
+if (!function_exists('invade')) {
953 953
     /**
954 954
      * Cette classe offre une fonction d'invasion qui vous permettra de lire / écrire des propriétés privées d'un objet.
955 955
      * Il vous permettra également de définir, obtenir et appeler des méthodes privées.
Please login to merge, or discard this patch.