mirror of
https://github.com/opensourcepos/opensourcepos.git
synced 2026-10-26 18:18:53 -04:00
Fix checkNumeric validation (#3872)
This commit is contained in:
1 parent
d69e7be848
commit
7d04371425
2 files changed
+6
-6
No files matched your search
@@ -89,14 +89,15 @@ class Secure_Controller extends BaseController
|
||||
*/
|
||||
public function getCheckNumeric(): void
|
||||
{
|
||||
$result = true;
|
||||
|
||||
foreach($this->request->getGet(null, FILTER_SANITIZE_FULL_SPECIAL_CHARS) as $value)
|
||||
{
|
||||
$result &= (int)parse_decimals($value);
|
||||
if (!parse_decimals($value))
|
||||
{
|
||||
echo 'false';
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
echo $result !== false ? 'true' : 'false';
|
||||
echo 'true';
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
Reference in new issue
Block a user