summaryrefslogtreecommitdiff
path: root/src/controller/Captcha.php
diff options
context:
space:
mode:
Diffstat (limited to 'src/controller/Captcha.php')
-rw-r--r--src/controller/Captcha.php2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/controller/Captcha.php b/src/controller/Captcha.php
index 3253b95..da61a53 100644
--- a/src/controller/Captcha.php
+++ b/src/controller/Captcha.php
@@ -44,7 +44,7 @@ class Captcha
44 } 44 }
45 static public function controlInput(string $input = '0'): int 45 static public function controlInput(string $input = '0'): int
46 { 46 {
47 // un POST est une chaîne qu'on doit convertir en nombre si: 47 // un POST est une chaîne qu'on doit convertir en nombre dans deux conditions:
48 // test de format: $input est un nombre 48 // test de format: $input est un nombre
49 // test d'intégrité: supprimer les décimales avec (int) ne change pas la valeur du nombre 49 // test d'intégrité: supprimer les décimales avec (int) ne change pas la valeur du nombre
50 return is_numeric($input) && $input == (int)$input ? (int)$input : 0; 50 return is_numeric($input) && $input == (int)$input ? (int)$input : 0;