forked from leftypol/leftypol
pages.php: slightly better ip error
This commit is contained in:
parent
d4781d6f00
commit
0c23445d72
1 changed files with 3 additions and 3 deletions
|
@ -854,7 +854,7 @@ function mod_ip_remove_note(Context $ctx, $ip, $id) {
|
|||
error($config['error']['noaccess']);
|
||||
|
||||
if (filter_var($ip, FILTER_VALIDATE_IP) === false)
|
||||
error("Invalid IP address.");
|
||||
error('Invalid IP address');
|
||||
|
||||
$query = prepare('DELETE FROM ``ip_notes`` WHERE `ip` = :ip AND `id` = :id');
|
||||
$query->bindValue(':ip', $ip);
|
||||
|
@ -870,7 +870,7 @@ function mod_ip(Context $ctx, $ip, string $encoded_cursor = null) {
|
|||
global $config, $mod;
|
||||
|
||||
if (filter_var($ip, FILTER_VALIDATE_IP) === false)
|
||||
error("Invalid IP address.");
|
||||
error('Invalid IP address');
|
||||
|
||||
if (isset($_POST['ban_id'], $_POST['unban'])) {
|
||||
if (!hasPermission($config['mod']['unban']))
|
||||
|
@ -922,7 +922,7 @@ function mod_user_posts_by_ip(Context $ctx, string $ip, string $encoded_cursor =
|
|||
global $mod;
|
||||
|
||||
if (\filter_var($ip, \FILTER_VALIDATE_IP) === false){
|
||||
error("Invalid IP address.");
|
||||
error('Invalid IP address');
|
||||
}
|
||||
|
||||
$config = $ctx->get('config');
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue