Minor improvements (#853)

This commit is contained in:
Roman Kelesidis 2023-08-10 22:45:29 +07:00 committed by GitHub
commit 0210000e34
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -144,6 +144,9 @@ switch ($field) {
case 'user_points':
$value = (float)str_replace(',', '.', $this->request['value']);
$value = sprintf('%.2f', $value);
if (strlen(strstr($value, '.', true)) > 14) {
$this->ajax_die($lang['WRONG_INPUT']);
}
$this->response['new_value'] = $value;
break;