@@ -16,7 +16,7 @@ discard block |
||
| 16 | 16 | * |
| 17 | 17 | * @credit <a href="https://codeigniter.com">CodeIgniter 4.2 - date_helper</a> |
| 18 | 18 | */ |
| 19 | -if (! function_exists('now')) { |
|
| 19 | +if (!function_exists('now')) { |
|
| 20 | 20 | /** |
| 21 | 21 | * Get "now" time |
| 22 | 22 | * |
@@ -53,7 +53,7 @@ discard block |
||
| 53 | 53 | } |
| 54 | 54 | } |
| 55 | 55 | |
| 56 | -if (! function_exists('timezone_select')) { |
|
| 56 | +if (!function_exists('timezone_select')) { |
|
| 57 | 57 | /** |
| 58 | 58 | * Generates a select field of all available timezones |
| 59 | 59 | * |
@@ -14,7 +14,7 @@ discard block |
||
| 14 | 14 | * |
| 15 | 15 | * @credit <a href="https://codeigniter.com">CodeIgniter 4.2 - number_helper</a> |
| 16 | 16 | */ |
| 17 | -if (! function_exists('number_to_size')) { |
|
| 17 | +if (!function_exists('number_to_size')) { |
|
| 18 | 18 | /** |
| 19 | 19 | * Formats a numbers as bytes, based on size, and adds the appropriate suffix |
| 20 | 20 | * |
@@ -34,7 +34,7 @@ discard block |
||
| 34 | 34 | |
| 35 | 35 | // ignore sub part |
| 36 | 36 | $generalLocale = $locale; |
| 37 | - if (! empty($locale) && ($underscorePos = strpos($locale, '_'))) { |
|
| 37 | + if (!empty($locale) && ($underscorePos = strpos($locale, '_'))) { |
|
| 38 | 38 | $generalLocale = substr($locale, 0, $underscorePos); |
| 39 | 39 | } |
| 40 | 40 | |
@@ -58,7 +58,7 @@ discard block |
||
| 58 | 58 | } |
| 59 | 59 | } |
| 60 | 60 | |
| 61 | -if (! function_exists('number_to_amount')) { |
|
| 61 | +if (!function_exists('number_to_amount')) { |
|
| 62 | 62 | /** |
| 63 | 63 | * Converts numbers to a more readable representation |
| 64 | 64 | * when dealing with very large numbers (in the thousands or above), |
@@ -87,7 +87,7 @@ discard block |
||
| 87 | 87 | |
| 88 | 88 | // ignore sub part |
| 89 | 89 | $generalLocale = $locale; |
| 90 | - if (! empty($locale) && ($underscorePos = strpos($locale, '_'))) { |
|
| 90 | + if (!empty($locale) && ($underscorePos = strpos($locale, '_'))) { |
|
| 91 | 91 | $generalLocale = substr($locale, 0, $underscorePos); |
| 92 | 92 | } |
| 93 | 93 | |
@@ -112,7 +112,7 @@ discard block |
||
| 112 | 112 | } |
| 113 | 113 | } |
| 114 | 114 | |
| 115 | -if (! function_exists('number_to_currency')) { |
|
| 115 | +if (!function_exists('number_to_currency')) { |
|
| 116 | 116 | function number_to_currency(float $num, string $currency, ?string $locale = null, int $fraction = 0): string |
| 117 | 117 | { |
| 118 | 118 | return format_number($num, 1, $locale, [ |
@@ -123,7 +123,7 @@ discard block |
||
| 123 | 123 | } |
| 124 | 124 | } |
| 125 | 125 | |
| 126 | -if (! function_exists('format_number')) { |
|
| 126 | +if (!function_exists('format_number')) { |
|
| 127 | 127 | /** |
| 128 | 128 | * A general purpose, locale-aware, number_format method. |
| 129 | 129 | * Used by all of the functions of the number_helper. |
@@ -172,7 +172,7 @@ discard block |
||
| 172 | 172 | } |
| 173 | 173 | } |
| 174 | 174 | |
| 175 | -if (! function_exists('number_to_roman')) { |
|
| 175 | +if (!function_exists('number_to_roman')) { |
|
| 176 | 176 | /** |
| 177 | 177 | * Convert a number to a roman numeral. |
| 178 | 178 | * |
@@ -23,7 +23,7 @@ discard block |
||
| 23 | 23 | |
| 24 | 24 | // ================================= FONCTIONS D'ACCESSIBILITE ================================= // |
| 25 | 25 | |
| 26 | -if (! function_exists('env')) { |
|
| 26 | +if (!function_exists('env')) { |
|
| 27 | 27 | /** |
| 28 | 28 | * Obtient une variable d'environnement à partir des sources disponibles et fournit une émulation |
| 29 | 29 | * pour les variables d'environnement non prises en charge ou incohérentes |
@@ -39,7 +39,7 @@ discard block |
||
| 39 | 39 | } |
| 40 | 40 | } |
| 41 | 41 | |
| 42 | -if (! function_exists('helper')) { |
|
| 42 | +if (!function_exists('helper')) { |
|
| 43 | 43 | /** |
| 44 | 44 | * Charge un fichier d'aide en mémoire. Prend en charge les assistants d'espace de noms, |
| 45 | 45 | * à la fois dans et hors du répertoire 'helpers' d'un répertoire à espace de noms. |
@@ -57,7 +57,7 @@ discard block |
||
| 57 | 57 | } |
| 58 | 58 | } |
| 59 | 59 | |
| 60 | -if (! function_exists('model')) { |
|
| 60 | +if (!function_exists('model')) { |
|
| 61 | 61 | /** |
| 62 | 62 | * Simple maniere d'obtenir un modele. |
| 63 | 63 | * |
@@ -67,13 +67,13 @@ discard block |
||
| 67 | 67 | * |
| 68 | 68 | * @return T |
| 69 | 69 | */ |
| 70 | - function model(string|array $name, array $options = [], ?ConnectionInterface &$conn = null) |
|
| 70 | + function model(string|array $name, array $options = [], ?ConnectionInterface&$conn = null) |
|
| 71 | 71 | { |
| 72 | 72 | return Load::model($name, $options, $conn); |
| 73 | 73 | } |
| 74 | 74 | } |
| 75 | 75 | |
| 76 | -if (! function_exists('service')) { |
|
| 76 | +if (!function_exists('service')) { |
|
| 77 | 77 | /** |
| 78 | 78 | * Permet un accès plus propre au fichier de configuration des services. |
| 79 | 79 | * Renvoie toujours une instance SHARED de la classe, donc |
@@ -90,7 +90,7 @@ discard block |
||
| 90 | 90 | } |
| 91 | 91 | } |
| 92 | 92 | |
| 93 | -if (! function_exists('single_service')) { |
|
| 93 | +if (!function_exists('single_service')) { |
|
| 94 | 94 | /** |
| 95 | 95 | * Autoriser l'accès propre à un service. |
| 96 | 96 | * Renvoie toujours une nouvelle instance de la classe. |
@@ -104,7 +104,7 @@ discard block |
||
| 104 | 104 | } |
| 105 | 105 | } |
| 106 | 106 | |
| 107 | -if (! function_exists('show404')) { |
|
| 107 | +if (!function_exists('show404')) { |
|
| 108 | 108 | /** |
| 109 | 109 | * Afficher une page 404 introuvable dans le navigateur |
| 110 | 110 | */ |
@@ -114,7 +114,7 @@ discard block |
||
| 114 | 114 | } |
| 115 | 115 | } |
| 116 | 116 | |
| 117 | -if (! function_exists('config')) { |
|
| 117 | +if (!function_exists('config')) { |
|
| 118 | 118 | /** |
| 119 | 119 | * GET/SET App config |
| 120 | 120 | * |
@@ -124,7 +124,7 @@ discard block |
||
| 124 | 124 | */ |
| 125 | 125 | function config(string $config, $value = null, bool $force_set = false) |
| 126 | 126 | { |
| 127 | - if (! empty($value) || (empty($value) && true === $force_set)) { |
|
| 127 | + if (!empty($value) || (empty($value) && true === $force_set)) { |
|
| 128 | 128 | Config::set($config, $value); |
| 129 | 129 | } |
| 130 | 130 | |
@@ -134,7 +134,7 @@ discard block |
||
| 134 | 134 | |
| 135 | 135 | // =========================== FONCTIONS DE PREVENTION D'ATTAQUE =========================== // |
| 136 | 136 | |
| 137 | -if (! function_exists('esc')) { |
|
| 137 | +if (!function_exists('esc')) { |
|
| 138 | 138 | /** |
| 139 | 139 | * Effectue un simple échappement automatique des données pour des raisons de sécurité. |
| 140 | 140 | * Pourrait envisager de rendre cela plus complexe à une date ultérieure. |
@@ -161,7 +161,7 @@ discard block |
||
| 161 | 161 | } |
| 162 | 162 | } |
| 163 | 163 | |
| 164 | -if (! function_exists('h')) { |
|
| 164 | +if (!function_exists('h')) { |
|
| 165 | 165 | /** |
| 166 | 166 | * Méthode pratique pour htmlspecialchars. |
| 167 | 167 | * |
@@ -180,7 +180,7 @@ discard block |
||
| 180 | 180 | } |
| 181 | 181 | } |
| 182 | 182 | |
| 183 | -if (! function_exists('purify')) { |
|
| 183 | +if (!function_exists('purify')) { |
|
| 184 | 184 | /** |
| 185 | 185 | * Purifiez l'entrée à l'aide de la classe autonome HTMLPurifier. |
| 186 | 186 | * Utilisez facilement plusieurs configurations de purificateur. |
@@ -198,7 +198,7 @@ discard block |
||
| 198 | 198 | } |
| 199 | 199 | } |
| 200 | 200 | |
| 201 | -if (! function_exists('remove_invisible_characters')) { |
|
| 201 | +if (!function_exists('remove_invisible_characters')) { |
|
| 202 | 202 | /** |
| 203 | 203 | * Supprimer les caractères invisibles |
| 204 | 204 | * |
@@ -211,7 +211,7 @@ discard block |
||
| 211 | 211 | } |
| 212 | 212 | } |
| 213 | 213 | |
| 214 | -if (! function_exists('stringify_attributes')) { |
|
| 214 | +if (!function_exists('stringify_attributes')) { |
|
| 215 | 215 | /** |
| 216 | 216 | * Chaîner les attributs à utiliser dans les balises HTML. |
| 217 | 217 | * |
@@ -225,7 +225,7 @@ discard block |
||
| 225 | 225 | |
| 226 | 226 | // ================================= FONCTIONS D'ENVIRONNEMENT D'EXECUTION ================================= // |
| 227 | 227 | |
| 228 | -if (! function_exists('on_dev')) { |
|
| 228 | +if (!function_exists('on_dev')) { |
|
| 229 | 229 | /** |
| 230 | 230 | * Testez pour voir si nous sommes dans un environnement de développement. |
| 231 | 231 | */ |
@@ -241,7 +241,7 @@ discard block |
||
| 241 | 241 | } |
| 242 | 242 | } |
| 243 | 243 | |
| 244 | -if (! function_exists('on_prod')) { |
|
| 244 | +if (!function_exists('on_prod')) { |
|
| 245 | 245 | /** |
| 246 | 246 | * Testez pour voir si nous sommes dans un environnement de production. |
| 247 | 247 | */ |
@@ -257,7 +257,7 @@ discard block |
||
| 257 | 257 | } |
| 258 | 258 | } |
| 259 | 259 | |
| 260 | -if (! function_exists('on_test')) { |
|
| 260 | +if (!function_exists('on_test')) { |
|
| 261 | 261 | /** |
| 262 | 262 | * Testez pour voir si nous sommes dans un environnement de test |
| 263 | 263 | */ |
@@ -269,7 +269,7 @@ discard block |
||
| 269 | 269 | } |
| 270 | 270 | } |
| 271 | 271 | |
| 272 | -if (! function_exists('is_cli')) { |
|
| 272 | +if (!function_exists('is_cli')) { |
|
| 273 | 273 | /** |
| 274 | 274 | * Testez pour voir si une demande a été faite à partir de la ligne de commande. |
| 275 | 275 | */ |
@@ -279,7 +279,7 @@ discard block |
||
| 279 | 279 | } |
| 280 | 280 | } |
| 281 | 281 | |
| 282 | -if (! function_exists('is_php')) { |
|
| 282 | +if (!function_exists('is_php')) { |
|
| 283 | 283 | /** |
| 284 | 284 | * Détermine si la version actuelle de PHP est égale ou supérieure à la valeur fournie. |
| 285 | 285 | */ |
@@ -289,7 +289,7 @@ discard block |
||
| 289 | 289 | } |
| 290 | 290 | } |
| 291 | 291 | |
| 292 | -if (! function_exists('is_windows')) { |
|
| 292 | +if (!function_exists('is_windows')) { |
|
| 293 | 293 | /** |
| 294 | 294 | * Déterminez si l'environnement actuel est basé sur Windows. |
| 295 | 295 | */ |
@@ -299,7 +299,7 @@ discard block |
||
| 299 | 299 | } |
| 300 | 300 | } |
| 301 | 301 | |
| 302 | -if (! function_exists('is_https')) { |
|
| 302 | +if (!function_exists('is_https')) { |
|
| 303 | 303 | /** |
| 304 | 304 | * Determines if the application is accessed via an encrypted * (HTTPS) connection. |
| 305 | 305 | */ |
@@ -309,7 +309,7 @@ discard block |
||
| 309 | 309 | } |
| 310 | 310 | } |
| 311 | 311 | |
| 312 | -if (! function_exists('is_localfile')) { |
|
| 312 | +if (!function_exists('is_localfile')) { |
|
| 313 | 313 | /** |
| 314 | 314 | * Vérifiez si le fichier auquel vous souhaitez accéder est un fichier local de votre application ou non |
| 315 | 315 | */ |
@@ -319,11 +319,11 @@ discard block |
||
| 319 | 319 | return true; |
| 320 | 320 | } |
| 321 | 321 | |
| 322 | - return ! preg_match('#^(https?://)#i', $name); |
|
| 322 | + return !preg_match('#^(https?://)#i', $name); |
|
| 323 | 323 | } |
| 324 | 324 | } |
| 325 | 325 | |
| 326 | -if (! function_exists('is_online')) { |
|
| 326 | +if (!function_exists('is_online')) { |
|
| 327 | 327 | /** |
| 328 | 328 | * Tester si l'application s'exécute en local ou en ligne. |
| 329 | 329 | */ |
@@ -333,7 +333,7 @@ discard block |
||
| 333 | 333 | } |
| 334 | 334 | } |
| 335 | 335 | |
| 336 | -if (! function_exists('is_connected')) { |
|
| 336 | +if (!function_exists('is_connected')) { |
|
| 337 | 337 | /** |
| 338 | 338 | * Verifie si l'utilisateur a une connexion internet active. |
| 339 | 339 | */ |
@@ -343,7 +343,7 @@ discard block |
||
| 343 | 343 | } |
| 344 | 344 | } |
| 345 | 345 | |
| 346 | -if (! function_exists('is_ajax_request')) { |
|
| 346 | +if (!function_exists('is_ajax_request')) { |
|
| 347 | 347 | /** |
| 348 | 348 | * Testez pour voir si une requête contient l'en-tête HTTP_X_REQUESTED_WITH. |
| 349 | 349 | */ |
@@ -353,7 +353,7 @@ discard block |
||
| 353 | 353 | } |
| 354 | 354 | } |
| 355 | 355 | |
| 356 | -if (! function_exists('redirection')) { |
|
| 356 | +if (!function_exists('redirection')) { |
|
| 357 | 357 | /** |
| 358 | 358 | * Redirige l'utilisateur |
| 359 | 359 | */ |
@@ -367,7 +367,7 @@ discard block |
||
| 367 | 367 | } |
| 368 | 368 | } |
| 369 | 369 | |
| 370 | -if (! function_exists('redirect')) { |
|
| 370 | +if (!function_exists('redirect')) { |
|
| 371 | 371 | /** |
| 372 | 372 | * Méthode pratique qui fonctionne avec la $request globale actuelle et |
| 373 | 373 | * l'instance $router à rediriger à l'aide de routes nommées et le routage inversé |
@@ -381,7 +381,7 @@ discard block |
||
| 381 | 381 | { |
| 382 | 382 | $redirection = Services::redirection(); |
| 383 | 383 | |
| 384 | - if (! empty($uri)) { |
|
| 384 | + if (!empty($uri)) { |
|
| 385 | 385 | return $redirection->route($uri); |
| 386 | 386 | } |
| 387 | 387 | |
@@ -389,7 +389,7 @@ discard block |
||
| 389 | 389 | } |
| 390 | 390 | } |
| 391 | 391 | |
| 392 | -if (! function_exists('link_to')) { |
|
| 392 | +if (!function_exists('link_to')) { |
|
| 393 | 393 | /** |
| 394 | 394 | * Étant donné une chaîne de contrôleur/méthode et tous les paramètres, |
| 395 | 395 | * tentera de créer l'URL relative à la route correspondante. |
@@ -405,7 +405,7 @@ discard block |
||
| 405 | 405 | } |
| 406 | 406 | } |
| 407 | 407 | |
| 408 | -if (! function_exists('clean_path')) { |
|
| 408 | +if (!function_exists('clean_path')) { |
|
| 409 | 409 | /** |
| 410 | 410 | * Une méthode pratique pour nettoyer les chemins pour |
| 411 | 411 | * une sortie plus belle. Utile pour les exceptions |
@@ -436,7 +436,7 @@ discard block |
||
| 436 | 436 | |
| 437 | 437 | // ================================= FONCTIONS DE DEBOGAGE ================================= // |
| 438 | 438 | |
| 439 | -if (! function_exists('dd')) { |
|
| 439 | +if (!function_exists('dd')) { |
|
| 440 | 440 | /** |
| 441 | 441 | * Prints a Kint debug report and exits. |
| 442 | 442 | * |
@@ -455,7 +455,7 @@ discard block |
||
| 455 | 455 | } |
| 456 | 456 | } |
| 457 | 457 | |
| 458 | -if (! function_exists('dump')) { |
|
| 458 | +if (!function_exists('dump')) { |
|
| 459 | 459 | /** |
| 460 | 460 | * Prints a Kint debug report and exits. |
| 461 | 461 | * |
@@ -472,7 +472,7 @@ discard block |
||
| 472 | 472 | } |
| 473 | 473 | } |
| 474 | 474 | |
| 475 | -if (! function_exists('deprecationWarning')) { |
|
| 475 | +if (!function_exists('deprecationWarning')) { |
|
| 476 | 476 | /** |
| 477 | 477 | * Méthode d'assistance pour générer des avertissements d'obsolescence |
| 478 | 478 | * |
@@ -488,7 +488,7 @@ discard block |
||
| 488 | 488 | } |
| 489 | 489 | } |
| 490 | 490 | |
| 491 | -if (! function_exists('logger')) { |
|
| 491 | +if (!function_exists('logger')) { |
|
| 492 | 492 | /** |
| 493 | 493 | * A convenience/compatibility method for logging events through |
| 494 | 494 | * the Log system. |
@@ -511,7 +511,7 @@ discard block |
||
| 511 | 511 | { |
| 512 | 512 | $logger = Services::logger(); |
| 513 | 513 | |
| 514 | - if (! empty($level) && ! empty($message)) { |
|
| 514 | + if (!empty($level) && !empty($message)) { |
|
| 515 | 515 | return $logger->log($level, $message, $context); |
| 516 | 516 | } |
| 517 | 517 | |
@@ -519,7 +519,7 @@ discard block |
||
| 519 | 519 | } |
| 520 | 520 | } |
| 521 | 521 | |
| 522 | -if (! function_exists('cache')) { |
|
| 522 | +if (!function_exists('cache')) { |
|
| 523 | 523 | /** |
| 524 | 524 | * Une méthode pratique qui donne accès au cache |
| 525 | 525 | * objet. Si aucun paramètre n'est fourni, renverra l'objet, |
@@ -549,7 +549,7 @@ discard block |
||
| 549 | 549 | } |
| 550 | 550 | } |
| 551 | 551 | |
| 552 | -if (! function_exists('pr')) { |
|
| 552 | +if (!function_exists('pr')) { |
|
| 553 | 553 | /** |
| 554 | 554 | * print_r() convenience function. |
| 555 | 555 | * |
@@ -571,7 +571,7 @@ discard block |
||
| 571 | 571 | } |
| 572 | 572 | } |
| 573 | 573 | |
| 574 | -if (! function_exists('pj')) { |
|
| 574 | +if (!function_exists('pj')) { |
|
| 575 | 575 | /** |
| 576 | 576 | * json pretty print convenience function. |
| 577 | 577 | * |
@@ -592,7 +592,7 @@ discard block |
||
| 592 | 592 | } |
| 593 | 593 | } |
| 594 | 594 | |
| 595 | -if (! function_exists('trigger_warning')) { |
|
| 595 | +if (!function_exists('trigger_warning')) { |
|
| 596 | 596 | /** |
| 597 | 597 | * Déclenche un E_USER_WARNING. |
| 598 | 598 | */ |
@@ -602,7 +602,7 @@ discard block |
||
| 602 | 602 | } |
| 603 | 603 | } |
| 604 | 604 | |
| 605 | -if (! function_exists('vd')) { |
|
| 605 | +if (!function_exists('vd')) { |
|
| 606 | 606 | /** |
| 607 | 607 | * Shortcut to ref, HTML mode |
| 608 | 608 | * |
@@ -614,7 +614,7 @@ discard block |
||
| 614 | 614 | } |
| 615 | 615 | } |
| 616 | 616 | |
| 617 | -if (! function_exists('vdt')) { |
|
| 617 | +if (!function_exists('vdt')) { |
|
| 618 | 618 | /** |
| 619 | 619 | * Shortcut to ref, plain text mode |
| 620 | 620 | * |
@@ -628,7 +628,7 @@ discard block |
||
| 628 | 628 | |
| 629 | 629 | // ================================= FONCTIONS DIVERSES ================================= // |
| 630 | 630 | |
| 631 | -if (! function_exists('force_https')) { |
|
| 631 | +if (!function_exists('force_https')) { |
|
| 632 | 632 | /** |
| 633 | 633 | * Utilisé pour forcer l'accès à une page via HTTPS. |
| 634 | 634 | * Utilise une redirection standard, plus définira l'en-tête HSTS |
@@ -686,7 +686,7 @@ discard block |
||
| 686 | 686 | } |
| 687 | 687 | } |
| 688 | 688 | |
| 689 | -if (! function_exists('getTypeName')) { |
|
| 689 | +if (!function_exists('getTypeName')) { |
|
| 690 | 690 | /** |
| 691 | 691 | * Renvoie la classe d'objets ou le type var de ce n'est pas un objet |
| 692 | 692 | * |
@@ -700,7 +700,7 @@ discard block |
||
| 700 | 700 | } |
| 701 | 701 | } |
| 702 | 702 | |
| 703 | -if (! function_exists('ip_address')) { |
|
| 703 | +if (!function_exists('ip_address')) { |
|
| 704 | 704 | /** |
| 705 | 705 | * Renvoie l'adresse IP de l'utilisateur actuel |
| 706 | 706 | */ |
@@ -710,7 +710,7 @@ discard block |
||
| 710 | 710 | } |
| 711 | 711 | } |
| 712 | 712 | |
| 713 | -if (! function_exists('is_really_writable')) { |
|
| 713 | +if (!function_exists('is_really_writable')) { |
|
| 714 | 714 | /** |
| 715 | 715 | * Tests d'inscriptibilité des fichiers |
| 716 | 716 | */ |
@@ -720,7 +720,7 @@ discard block |
||
| 720 | 720 | } |
| 721 | 721 | } |
| 722 | 722 | |
| 723 | -if (! function_exists('lang')) { |
|
| 723 | +if (!function_exists('lang')) { |
|
| 724 | 724 | /** |
| 725 | 725 | * Une méthode pratique pour traduire une chaîne ou un tableau d'entrées et formater |
| 726 | 726 | * le résultat avec le MessageFormatter de l'extension intl. |
@@ -736,7 +736,7 @@ discard block |
||
| 736 | 736 | } |
| 737 | 737 | } |
| 738 | 738 | |
| 739 | -if (! function_exists('namespace_split')) { |
|
| 739 | +if (!function_exists('namespace_split')) { |
|
| 740 | 740 | /** |
| 741 | 741 | * Séparez l'espace de noms du nom de classe. |
| 742 | 742 | * |
@@ -757,7 +757,7 @@ discard block |
||
| 757 | 757 | } |
| 758 | 758 | } |
| 759 | 759 | |
| 760 | -if (! function_exists('view_exist')) { |
|
| 760 | +if (!function_exists('view_exist')) { |
|
| 761 | 761 | /** |
| 762 | 762 | * Verifie si un fichier de vue existe. Utile pour limiter les failles include |
| 763 | 763 | */ |
@@ -771,7 +771,7 @@ discard block |
||
| 771 | 771 | } |
| 772 | 772 | } |
| 773 | 773 | |
| 774 | -if (! function_exists('view')) { |
|
| 774 | +if (!function_exists('view')) { |
|
| 775 | 775 | /** |
| 776 | 776 | * Charge une vue |
| 777 | 777 | * |
@@ -787,7 +787,7 @@ discard block |
||
| 787 | 787 | } |
| 788 | 788 | } |
| 789 | 789 | |
| 790 | -if (! function_exists('flash')) { |
|
| 790 | +if (!function_exists('flash')) { |
|
| 791 | 791 | /** |
| 792 | 792 | * Fournisseur d'acces rapide a la classe PHP Flash |
| 793 | 793 | * |
@@ -819,7 +819,7 @@ discard block |
||
| 819 | 819 | }*/ |
| 820 | 820 | } |
| 821 | 821 | |
| 822 | -if (! function_exists('geo_ip')) { |
|
| 822 | +if (!function_exists('geo_ip')) { |
|
| 823 | 823 | /** |
| 824 | 824 | * Recuperation des coordonnees (pays, ville, etc) d'un utilisateur en fonction de son ip |
| 825 | 825 | */ |
@@ -829,7 +829,7 @@ discard block |
||
| 829 | 829 | } |
| 830 | 830 | } |
| 831 | 831 | |
| 832 | -if (! function_exists('to_stream')) { |
|
| 832 | +if (!function_exists('to_stream')) { |
|
| 833 | 833 | /** |
| 834 | 834 | * Créez un nouveau flux basé sur le type d'entrée. |
| 835 | 835 | * |
@@ -852,7 +852,7 @@ discard block |
||
| 852 | 852 | } |
| 853 | 853 | } |
| 854 | 854 | |
| 855 | -if (! function_exists('value')) { |
|
| 855 | +if (!function_exists('value')) { |
|
| 856 | 856 | /** |
| 857 | 857 | * Renvoie la valeur par défaut de la valeur donnée. |
| 858 | 858 | */ |
@@ -862,7 +862,7 @@ discard block |
||
| 862 | 862 | } |
| 863 | 863 | } |
| 864 | 864 | |
| 865 | -if (! function_exists('collect')) { |
|
| 865 | +if (!function_exists('collect')) { |
|
| 866 | 866 | /** |
| 867 | 867 | * Créez une collection à partir de la valeur donnée. |
| 868 | 868 | */ |
@@ -872,7 +872,7 @@ discard block |
||
| 872 | 872 | } |
| 873 | 873 | } |
| 874 | 874 | |
| 875 | -if (! function_exists('with')) { |
|
| 875 | +if (!function_exists('with')) { |
|
| 876 | 876 | /** |
| 877 | 877 | * Renvoie la valeur donnée, éventuellement transmise via le rappel donné. |
| 878 | 878 | * |
@@ -884,7 +884,7 @@ discard block |
||
| 884 | 884 | } |
| 885 | 885 | } |
| 886 | 886 | |
| 887 | -if (! function_exists('tap')) { |
|
| 887 | +if (!function_exists('tap')) { |
|
| 888 | 888 | /** |
| 889 | 889 | * Appelez la Closure donnée avec cette instance puis renvoyez l'instance. |
| 890 | 890 | */ |
@@ -9,7 +9,7 @@ discard block |
||
| 9 | 9 | * the LICENSE file that was distributed with this source code. |
| 10 | 10 | */ |
| 11 | 11 | |
| 12 | -if (! function_exists('css_url')) { |
|
| 12 | +if (!function_exists('css_url')) { |
|
| 13 | 13 | /** |
| 14 | 14 | * CSS URL |
| 15 | 15 | * |
@@ -23,17 +23,17 @@ discard block |
||
| 23 | 23 | $name = str_replace(site_url() . 'css/', '', htmlspecialchars($name)); |
| 24 | 24 | |
| 25 | 25 | if (is_localfile($name)) { |
| 26 | - $name .= (! preg_match('#\.css$#i', $name) ? '.css' : ''); |
|
| 26 | + $name .= (!preg_match('#\.css$#i', $name) ? '.css' : ''); |
|
| 27 | 27 | $filename = WEBROOT . 'css' . DS . $name; |
| 28 | 28 | |
| 29 | 29 | return site_url() . 'css/' . $name . ((file_exists($filename)) ? '?v=' . filemtime($filename) : ''); |
| 30 | 30 | } |
| 31 | 31 | |
| 32 | - return $name . (! preg_match('#\.css$#i', $name) ? '.css' : ''); |
|
| 32 | + return $name . (!preg_match('#\.css$#i', $name) ? '.css' : ''); |
|
| 33 | 33 | } |
| 34 | 34 | } |
| 35 | 35 | |
| 36 | -if (! function_exists('js_url')) { |
|
| 36 | +if (!function_exists('js_url')) { |
|
| 37 | 37 | /** |
| 38 | 38 | * JS URL |
| 39 | 39 | * |
@@ -47,17 +47,17 @@ discard block |
||
| 47 | 47 | $name = str_replace(site_url() . 'js/', '', htmlspecialchars($name)); |
| 48 | 48 | |
| 49 | 49 | if (is_localfile($name)) { |
| 50 | - $name .= (! preg_match('#\.js$#i', $name) ? '.js' : ''); |
|
| 50 | + $name .= (!preg_match('#\.js$#i', $name) ? '.js' : ''); |
|
| 51 | 51 | $filename = WEBROOT . 'js' . DS . $name; |
| 52 | 52 | |
| 53 | 53 | return site_url() . 'js/' . $name . ((file_exists($filename)) ? '?v=' . filemtime($filename) : ''); |
| 54 | 54 | } |
| 55 | 55 | |
| 56 | - return $name . (! preg_match('#\.js$#i', $name) ? '.js' : ''); |
|
| 56 | + return $name . (!preg_match('#\.js$#i', $name) ? '.js' : ''); |
|
| 57 | 57 | } |
| 58 | 58 | } |
| 59 | 59 | |
| 60 | -if (! function_exists('lib_css_url')) { |
|
| 60 | +if (!function_exists('lib_css_url')) { |
|
| 61 | 61 | /** |
| 62 | 62 | * LIB CSS URL |
| 63 | 63 | * |
@@ -71,17 +71,17 @@ discard block |
||
| 71 | 71 | $name = str_replace(site_url() . 'lib/', '', htmlspecialchars($name)); |
| 72 | 72 | |
| 73 | 73 | if (is_localfile($name)) { |
| 74 | - $name .= (! preg_match('#\.css$#i', $name) ? '.css' : ''); |
|
| 74 | + $name .= (!preg_match('#\.css$#i', $name) ? '.css' : ''); |
|
| 75 | 75 | $filename = WEBROOT . 'lib' . DS . $name; |
| 76 | 76 | |
| 77 | 77 | return site_url() . 'lib/' . $name . ((file_exists($filename)) ? '?v=' . filemtime($filename) : ''); |
| 78 | 78 | } |
| 79 | 79 | |
| 80 | - return $name . (! preg_match('#\.css$#i', $name) ? '.css' : ''); |
|
| 80 | + return $name . (!preg_match('#\.css$#i', $name) ? '.css' : ''); |
|
| 81 | 81 | } |
| 82 | 82 | } |
| 83 | 83 | |
| 84 | -if (! function_exists('lib_js_url')) { |
|
| 84 | +if (!function_exists('lib_js_url')) { |
|
| 85 | 85 | /** |
| 86 | 86 | * LIB JS URL |
| 87 | 87 | * |
@@ -95,17 +95,17 @@ discard block |
||
| 95 | 95 | $name = str_replace(site_url() . 'lib/', '', htmlspecialchars($name)); |
| 96 | 96 | |
| 97 | 97 | if (is_localfile($name)) { |
| 98 | - $name .= (! preg_match('#\.js$#i', $name) ? '.js' : ''); |
|
| 98 | + $name .= (!preg_match('#\.js$#i', $name) ? '.js' : ''); |
|
| 99 | 99 | $filename = WEBROOT . 'lib' . DS . $name; |
| 100 | 100 | |
| 101 | 101 | return site_url() . 'lib/' . $name . ((file_exists($filename)) ? '?v=' . filemtime($filename) : ''); |
| 102 | 102 | } |
| 103 | 103 | |
| 104 | - return $name . (! preg_match('#\.js$#i', $name) ? '.js' : ''); |
|
| 104 | + return $name . (!preg_match('#\.js$#i', $name) ? '.js' : ''); |
|
| 105 | 105 | } |
| 106 | 106 | } |
| 107 | 107 | |
| 108 | -if (! function_exists('lib_styles')) { |
|
| 108 | +if (!function_exists('lib_styles')) { |
|
| 109 | 109 | /** |
| 110 | 110 | * LIB_STYLES |
| 111 | 111 | * |
@@ -123,7 +123,7 @@ discard block |
||
| 123 | 123 | |
| 124 | 124 | foreach ($name as $style) { |
| 125 | 125 | if (is_string($style)) { |
| 126 | - $style = (! preg_match('#\.css$#i', $style) ? $style . '.css' : $style); |
|
| 126 | + $style = (!preg_match('#\.css$#i', $style) ? $style . '.css' : $style); |
|
| 127 | 127 | if (is_file(WEBROOT . 'lib' . DS . str_replace('/', DS, $style))) { |
| 128 | 128 | $return[] = '<link rel="preload" type="text/css" href="' . lib_css_url($style) . '" as="style"> |
| 129 | 129 | <link rel="stylesheet" type="text/css" href="' . lib_css_url($style) . '" />'; |
@@ -147,7 +147,7 @@ discard block |
||
| 147 | 147 | } |
| 148 | 148 | } |
| 149 | 149 | |
| 150 | -if (! function_exists('lib_scripts')) { |
|
| 150 | +if (!function_exists('lib_scripts')) { |
|
| 151 | 151 | /** |
| 152 | 152 | * LIB_SCRIPTS |
| 153 | 153 | * |
@@ -165,7 +165,7 @@ discard block |
||
| 165 | 165 | |
| 166 | 166 | foreach ($name as $script) { |
| 167 | 167 | if (is_string($script)) { |
| 168 | - $script = (! preg_match('#\.js$#i', $script) ? $script . '.js' : $script); |
|
| 168 | + $script = (!preg_match('#\.js$#i', $script) ? $script . '.js' : $script); |
|
| 169 | 169 | if (is_file(WEBROOT . 'lib' . DS . str_replace('/', DS, $script))) { |
| 170 | 170 | $return[] = '<script type="text/javascript" src="' . lib_js_url($script) . '"></script>'; |
| 171 | 171 | } elseif (is_localfile($script)) { |
@@ -187,7 +187,7 @@ discard block |
||
| 187 | 187 | } |
| 188 | 188 | } |
| 189 | 189 | |
| 190 | -if (! function_exists('styles')) { |
|
| 190 | +if (!function_exists('styles')) { |
|
| 191 | 191 | /** |
| 192 | 192 | * STYLES |
| 193 | 193 | * |
@@ -205,7 +205,7 @@ discard block |
||
| 205 | 205 | |
| 206 | 206 | foreach ($name as $style) { |
| 207 | 207 | if (is_string($style)) { |
| 208 | - $style = (! preg_match('#\.css$#i', $style) ? $style . '.css' : $style); |
|
| 208 | + $style = (!preg_match('#\.css$#i', $style) ? $style . '.css' : $style); |
|
| 209 | 209 | if (is_file(WEBROOT . 'css' . DS . str_replace('/', DS, $style))) { |
| 210 | 210 | $return[] = '<link rel="preload" type="text/css" href="' . css_url($style) . '" as="style"> |
| 211 | 211 | <link rel="stylesheet" type="text/css" href="' . css_url($style) . '" />'; |
@@ -229,7 +229,7 @@ discard block |
||
| 229 | 229 | } |
| 230 | 230 | } |
| 231 | 231 | |
| 232 | -if (! function_exists('scripts')) { |
|
| 232 | +if (!function_exists('scripts')) { |
|
| 233 | 233 | /** |
| 234 | 234 | * SCRIPTS |
| 235 | 235 | * |
@@ -247,7 +247,7 @@ discard block |
||
| 247 | 247 | |
| 248 | 248 | foreach ($name as $script) { |
| 249 | 249 | if (is_string($script)) { |
| 250 | - $script = (! preg_match('#\.js$#i', $script) ? $script . '.js' : $script); |
|
| 250 | + $script = (!preg_match('#\.js$#i', $script) ? $script . '.js' : $script); |
|
| 251 | 251 | if (is_file(WEBROOT . 'js' . DS . str_replace('/', DS, $script))) { |
| 252 | 252 | $return[] = '<script type="text/javascript" src="' . js_url($script) . '"></script>'; |
| 253 | 253 | } elseif (is_localfile($script)) { |
@@ -269,7 +269,7 @@ discard block |
||
| 269 | 269 | } |
| 270 | 270 | } |
| 271 | 271 | |
| 272 | -if (! function_exists('less_url')) { |
|
| 272 | +if (!function_exists('less_url')) { |
|
| 273 | 273 | /** |
| 274 | 274 | * LESS URL |
| 275 | 275 | * |
@@ -283,17 +283,17 @@ discard block |
||
| 283 | 283 | $name = str_replace(site_url() . 'less/', '', htmlspecialchars($name)); |
| 284 | 284 | |
| 285 | 285 | if (is_localfile($name)) { |
| 286 | - $name .= (! preg_match('#\.less$#i', $name) ? '.less' : ''); |
|
| 286 | + $name .= (!preg_match('#\.less$#i', $name) ? '.less' : ''); |
|
| 287 | 287 | $filename = WEBROOT . 'less' . DS . $name; |
| 288 | 288 | |
| 289 | 289 | return site_url() . 'less/' . $name . ((file_exists($filename)) ? '?v=' . filemtime($filename) : ''); |
| 290 | 290 | } |
| 291 | 291 | |
| 292 | - return $name . (! preg_match('#\.less$#i', $name) ? '.less' : ''); |
|
| 292 | + return $name . (!preg_match('#\.less$#i', $name) ? '.less' : ''); |
|
| 293 | 293 | } |
| 294 | 294 | } |
| 295 | 295 | |
| 296 | -if (! function_exists('less_styles')) { |
|
| 296 | +if (!function_exists('less_styles')) { |
|
| 297 | 297 | /** |
| 298 | 298 | * LESS_STYLES |
| 299 | 299 | * |
@@ -311,7 +311,7 @@ discard block |
||
| 311 | 311 | |
| 312 | 312 | foreach ($name as $style) { |
| 313 | 313 | if (is_string($style)) { |
| 314 | - $style = (! preg_match('#\.less$#i', $style) ? $style . '.less' : $style); |
|
| 314 | + $style = (!preg_match('#\.less$#i', $style) ? $style . '.less' : $style); |
|
| 315 | 315 | if (is_file(WEBROOT . 'less' . DS . str_replace('/', DS, $style))) { |
| 316 | 316 | $return[] = '<link rel="stylesheet" type="text/less" href="' . less_url($style) . '" />'; |
| 317 | 317 | } elseif (is_localfile($style)) { |
@@ -333,7 +333,7 @@ discard block |
||
| 333 | 333 | } |
| 334 | 334 | } |
| 335 | 335 | |
| 336 | -if (! function_exists('img_url')) { |
|
| 336 | +if (!function_exists('img_url')) { |
|
| 337 | 337 | /** |
| 338 | 338 | * IMG URL |
| 339 | 339 | * |
@@ -360,7 +360,7 @@ discard block |
||
| 360 | 360 | } |
| 361 | 361 | } |
| 362 | 362 | |
| 363 | -if (! function_exists('img')) { |
|
| 363 | +if (!function_exists('img')) { |
|
| 364 | 364 | /** |
| 365 | 365 | * IMG |
| 366 | 366 | * |
@@ -391,7 +391,7 @@ discard block |
||
| 391 | 391 | } |
| 392 | 392 | } |
| 393 | 393 | |
| 394 | -if (! function_exists('docs_url')) { |
|
| 394 | +if (!function_exists('docs_url')) { |
|
| 395 | 395 | /** |
| 396 | 396 | * DOCS URL |
| 397 | 397 | * |
@@ -418,7 +418,7 @@ discard block |
||
| 418 | 418 | } |
| 419 | 419 | } |
| 420 | 420 | |
| 421 | -if (! function_exists('videos_url')) { |
|
| 421 | +if (!function_exists('videos_url')) { |
|
| 422 | 422 | /** |
| 423 | 423 | * VIDEOS URL |
| 424 | 424 | * |
@@ -11,7 +11,7 @@ discard block |
||
| 11 | 11 | |
| 12 | 12 | use BlitzPHP\Utilities\String\Inflector; |
| 13 | 13 | |
| 14 | -if (! function_exists('camelize')) { |
|
| 14 | +if (!function_exists('camelize')) { |
|
| 15 | 15 | /** |
| 16 | 16 | * Camelize |
| 17 | 17 | * |
@@ -25,7 +25,7 @@ discard block |
||
| 25 | 25 | } |
| 26 | 26 | } |
| 27 | 27 | |
| 28 | -if (! function_exists('classify')) { |
|
| 28 | +if (!function_exists('classify')) { |
|
| 29 | 29 | /** |
| 30 | 30 | * Returns model class name ("Person" for the database table "people".) for given database table. |
| 31 | 31 | * |
@@ -39,7 +39,7 @@ discard block |
||
| 39 | 39 | } |
| 40 | 40 | } |
| 41 | 41 | |
| 42 | -if (! function_exists('dasherize')) { |
|
| 42 | +if (!function_exists('dasherize')) { |
|
| 43 | 43 | /** |
| 44 | 44 | * Returns the input CamelCasedString as an dashed-string. |
| 45 | 45 | * |
@@ -55,7 +55,7 @@ discard block |
||
| 55 | 55 | } |
| 56 | 56 | } |
| 57 | 57 | |
| 58 | -if (! function_exists('delimit')) { |
|
| 58 | +if (!function_exists('delimit')) { |
|
| 59 | 59 | /** |
| 60 | 60 | * Expects a CamelCasedInputString, and produces a lower_case_delimited_string |
| 61 | 61 | * |
@@ -70,7 +70,7 @@ discard block |
||
| 70 | 70 | } |
| 71 | 71 | } |
| 72 | 72 | |
| 73 | -if (! function_exists('humanize')) { |
|
| 73 | +if (!function_exists('humanize')) { |
|
| 74 | 74 | /** |
| 75 | 75 | * Humanize |
| 76 | 76 | * |
@@ -85,7 +85,7 @@ discard block |
||
| 85 | 85 | } |
| 86 | 86 | } |
| 87 | 87 | |
| 88 | -if (! function_exists('plural')) { |
|
| 88 | +if (!function_exists('plural')) { |
|
| 89 | 89 | /** |
| 90 | 90 | * Plural |
| 91 | 91 | * |
@@ -99,30 +99,30 @@ discard block |
||
| 99 | 99 | { |
| 100 | 100 | $result = (string) $str; |
| 101 | 101 | |
| 102 | - if (! is_countable($result)) { |
|
| 102 | + if (!is_countable($result)) { |
|
| 103 | 103 | return $result; |
| 104 | 104 | } |
| 105 | 105 | |
| 106 | 106 | $plural_rules = [ |
| 107 | - '/(quiz)$/' => '\1zes', // quizzes |
|
| 108 | - '/^(ox)$/' => '\1\2en', // ox |
|
| 109 | - '/([m|l])ouse$/' => '\1ice', // mouse, louse |
|
| 110 | - '/(matr|vert|ind)ix|ex$/' => '\1ices', // matrix, vertex, index |
|
| 111 | - '/(x|ch|ss|sh)$/' => '\1es', // search, switch, fix, box, process, address |
|
| 112 | - '/([^aeiouy]|qu)y$/' => '\1ies', // query, ability, agency |
|
| 113 | - '/(hive)$/' => '\1s', // archive, hive |
|
| 114 | - '/(?:([^f])fe|([lr])f)$/' => '\1\2ves', // half, safe, wife |
|
| 115 | - '/sis$/' => 'ses', // basis, diagnosis |
|
| 116 | - '/([ti])um$/' => '\1a', // datum, medium |
|
| 117 | - '/(p)erson$/' => '\1eople', // person, salesperson |
|
| 118 | - '/(m)an$/' => '\1en', // man, woman, spokesman |
|
| 119 | - '/(c)hild$/' => '\1hildren', // child |
|
| 120 | - '/(buffal|tomat)o$/' => '\1\2oes', // buffalo, tomato |
|
| 121 | - '/(bu|campu)s$/' => '\1\2ses', // bus, campus |
|
| 122 | - '/(alias|status|virus)$/' => '\1es', // alias |
|
| 123 | - '/(octop)us$/' => '\1i', // octopus |
|
| 124 | - '/(ax|cris|test)is$/' => '\1es', // axis, crisis |
|
| 125 | - '/s$/' => 's', // no change (compatibility) |
|
| 107 | + '/(quiz)$/' => '\1zes', // quizzes |
|
| 108 | + '/^(ox)$/' => '\1\2en', // ox |
|
| 109 | + '/([m|l])ouse$/' => '\1ice', // mouse, louse |
|
| 110 | + '/(matr|vert|ind)ix|ex$/' => '\1ices', // matrix, vertex, index |
|
| 111 | + '/(x|ch|ss|sh)$/' => '\1es', // search, switch, fix, box, process, address |
|
| 112 | + '/([^aeiouy]|qu)y$/' => '\1ies', // query, ability, agency |
|
| 113 | + '/(hive)$/' => '\1s', // archive, hive |
|
| 114 | + '/(?:([^f])fe|([lr])f)$/' => '\1\2ves', // half, safe, wife |
|
| 115 | + '/sis$/' => 'ses', // basis, diagnosis |
|
| 116 | + '/([ti])um$/' => '\1a', // datum, medium |
|
| 117 | + '/(p)erson$/' => '\1eople', // person, salesperson |
|
| 118 | + '/(m)an$/' => '\1en', // man, woman, spokesman |
|
| 119 | + '/(c)hild$/' => '\1hildren', // child |
|
| 120 | + '/(buffal|tomat)o$/' => '\1\2oes', // buffalo, tomato |
|
| 121 | + '/(bu|campu)s$/' => '\1\2ses', // bus, campus |
|
| 122 | + '/(alias|status|virus)$/' => '\1es', // alias |
|
| 123 | + '/(octop)us$/' => '\1i', // octopus |
|
| 124 | + '/(ax|cris|test)is$/' => '\1es', // axis, crisis |
|
| 125 | + '/s$/' => 's', // no change (compatibility) |
|
| 126 | 126 | '/$/' => 's', |
| 127 | 127 | ]; |
| 128 | 128 | |
@@ -137,7 +137,7 @@ discard block |
||
| 137 | 137 | } |
| 138 | 138 | } |
| 139 | 139 | |
| 140 | -if (! function_exists('pluralize')) { |
|
| 140 | +if (!function_exists('pluralize')) { |
|
| 141 | 141 | /** |
| 142 | 142 | * Return $word in plural form. |
| 143 | 143 | * |
@@ -151,7 +151,7 @@ discard block |
||
| 151 | 151 | } |
| 152 | 152 | } |
| 153 | 153 | |
| 154 | -if (! function_exists('singular')) { |
|
| 154 | +if (!function_exists('singular')) { |
|
| 155 | 155 | /** |
| 156 | 156 | * Singular |
| 157 | 157 | * |
@@ -165,7 +165,7 @@ discard block |
||
| 165 | 165 | { |
| 166 | 166 | $result = (string) $str; |
| 167 | 167 | |
| 168 | - if (! is_countable($result)) { |
|
| 168 | + if (!is_countable($result)) { |
|
| 169 | 169 | return $result; |
| 170 | 170 | } |
| 171 | 171 | |
@@ -211,7 +211,7 @@ discard block |
||
| 211 | 211 | } |
| 212 | 212 | } |
| 213 | 213 | |
| 214 | -if (! function_exists('singularize')) { |
|
| 214 | +if (!function_exists('singularize')) { |
|
| 215 | 215 | /** |
| 216 | 216 | * Return $word in singular form. |
| 217 | 217 | * |
@@ -225,7 +225,7 @@ discard block |
||
| 225 | 225 | } |
| 226 | 226 | } |
| 227 | 227 | |
| 228 | -if (! function_exists('tableize')) { |
|
| 228 | +if (!function_exists('tableize')) { |
|
| 229 | 229 | /** |
| 230 | 230 | * Returns corresponding table name for given model $className. ("people" for the model class "Person"). |
| 231 | 231 | * |
@@ -239,7 +239,7 @@ discard block |
||
| 239 | 239 | } |
| 240 | 240 | } |
| 241 | 241 | |
| 242 | -if (! function_exists('underscore')) { |
|
| 242 | +if (!function_exists('underscore')) { |
|
| 243 | 243 | /** |
| 244 | 244 | * Underscore |
| 245 | 245 | * |
@@ -253,7 +253,7 @@ discard block |
||
| 253 | 253 | } |
| 254 | 254 | } |
| 255 | 255 | |
| 256 | -if (! function_exists('variable')) { |
|
| 256 | +if (!function_exists('variable')) { |
|
| 257 | 257 | /** |
| 258 | 258 | * Returns camelBacked version of an underscored string. |
| 259 | 259 | * |
@@ -267,7 +267,7 @@ discard block |
||
| 267 | 267 | } |
| 268 | 268 | } |
| 269 | 269 | |
| 270 | -if (! function_exists('counted')) { |
|
| 270 | +if (!function_exists('counted')) { |
|
| 271 | 271 | /** |
| 272 | 272 | * Counted |
| 273 | 273 | * |
@@ -285,7 +285,7 @@ discard block |
||
| 285 | 285 | } |
| 286 | 286 | } |
| 287 | 287 | |
| 288 | -if (! function_exists('pascalize')) { |
|
| 288 | +if (!function_exists('pascalize')) { |
|
| 289 | 289 | /** |
| 290 | 290 | * Pascalize |
| 291 | 291 | * |
@@ -301,7 +301,7 @@ discard block |
||
| 301 | 301 | } |
| 302 | 302 | } |
| 303 | 303 | |
| 304 | -if (! function_exists('is_pluralizable')) { |
|
| 304 | +if (!function_exists('is_pluralizable')) { |
|
| 305 | 305 | /** |
| 306 | 306 | * Checks if the given word has a plural version. |
| 307 | 307 | * |
@@ -309,7 +309,7 @@ discard block |
||
| 309 | 309 | */ |
| 310 | 310 | function is_pluralizable(string $word): bool |
| 311 | 311 | { |
| 312 | - return ! in_array( |
|
| 312 | + return !in_array( |
|
| 313 | 313 | strtolower($word), |
| 314 | 314 | [ |
| 315 | 315 | 'advice', |
@@ -384,7 +384,7 @@ discard block |
||
| 384 | 384 | } |
| 385 | 385 | } |
| 386 | 386 | |
| 387 | -if (! function_exists('ordinal')) { |
|
| 387 | +if (!function_exists('ordinal')) { |
|
| 388 | 388 | /** |
| 389 | 389 | * Returns the suffix that should be added to a |
| 390 | 390 | * number to denote the position in an ordered |
@@ -411,7 +411,7 @@ discard block |
||
| 411 | 411 | } |
| 412 | 412 | } |
| 413 | 413 | |
| 414 | -if (! function_exists('ordinalize')) { |
|
| 414 | +if (!function_exists('ordinalize')) { |
|
| 415 | 415 | /** |
| 416 | 416 | * Turns a number into an ordinal string used |
| 417 | 417 | * to denote the position in an ordered sequence |
@@ -54,7 +54,7 @@ discard block |
||
| 54 | 54 | $config = config('cache'); |
| 55 | 55 | $handler = $this->argument('driver', $config['handler']); |
| 56 | 56 | |
| 57 | - if (! array_key_exists($handler, $config['valid_handlers'])) { |
|
| 57 | + if (!array_key_exists($handler, $config['valid_handlers'])) { |
|
| 58 | 58 | $this->fail($handler . 'n\'est pas un gestionnaire de cache valide.'); |
| 59 | 59 | |
| 60 | 60 | return; |
@@ -63,7 +63,7 @@ discard block |
||
| 63 | 63 | $config['handler'] = $handler; |
| 64 | 64 | $cache = Services::cache($config); |
| 65 | 65 | |
| 66 | - if (! $cache->clear()) { |
|
| 66 | + if (!$cache->clear()) { |
|
| 67 | 67 | // @codeCoverageIgnoreStart |
| 68 | 68 | $this->fail('Erreur lors de l\'effacement du cache.'); |
| 69 | 69 | |
@@ -69,7 +69,7 @@ |
||
| 69 | 69 | 'nom' => $key, |
| 70 | 70 | 'chemin du serveur' => clean_path($field['server_path']), |
| 71 | 71 | 'taille' => number_to_size($field['size']), |
| 72 | - 'date' => $field['date'], // @todo formatter avec Utilities\Date |
|
| 72 | + 'date' => $field['date'], // @todo formatter avec Utilities\Date |
|
| 73 | 73 | ]; |
| 74 | 74 | } |
| 75 | 75 | |
@@ -56,7 +56,7 @@ |
||
| 56 | 56 | { |
| 57 | 57 | $name = $this->argument('name'); |
| 58 | 58 | if (empty($name)) { |
| 59 | - $name = $this->prompt(lang('Migrations.migSeeder'), null, static function ($val) { |
|
| 59 | + $name = $this->prompt(lang('Migrations.migSeeder'), null, static function($val) { |
|
| 60 | 60 | if (empty($val)) { |
| 61 | 61 | throw new InvalidArgumentException('Veuillez entrer le nom du seeder.'); |
| 62 | 62 | } |
@@ -63,7 +63,7 @@ |
||
| 63 | 63 | $runner->clearMessages(); |
| 64 | 64 | $runner->setFiles(Helper::getMigrationFiles($this->option('all') === true, $namespace)); |
| 65 | 65 | |
| 66 | - if (! $runner->latest($group)) { |
|
| 66 | + if (!$runner->latest($group)) { |
|
| 67 | 67 | $this->fail(lang('Migrations.generalFault')); // @codeCoverageIgnore |
| 68 | 68 | } |
| 69 | 69 | |