Use strip_tags() for error message in ajax_die() (#990)

This commit is contained in:
Roman Kelesidis 2023-10-26 15:07:39 +07:00 committed by GitHub
commit 8765aaaa3a
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
3 changed files with 4 additions and 4 deletions

View file

@ -27,7 +27,7 @@ switch ($field) {
case 'username':
$value = clean_username($value);
if ($err = \TorrentPier\Validate::username($value)) {
$this->ajax_die(strip_tags($err));
$this->ajax_die($err);
}
$this->response['new_value'] = $this->request['value'];
break;