mirror of
https://github.com/pragma-/pbot.git
synced 2024-12-23 11:12:42 +01:00
Users: lowercase key in userset
This commit is contained in:
parent
ef4580b2e0
commit
9abc92486d
@ -276,6 +276,8 @@ sub cmd_userset {
|
||||
return "There is no user account $name.";
|
||||
}
|
||||
|
||||
$key = lc $key;
|
||||
|
||||
if (defined $value and not $self->{pbot}->{capabilities}->userhas($u, 'can-modify-capabilities')) {
|
||||
if ($key =~ m/^can-/i or $self->{pbot}->{capabilities}->exists($key)) {
|
||||
return "The $key metadata requires the can-modify-capabilities capability, which your user account does not have.";
|
||||
|
Loading…
Reference in New Issue
Block a user