3
0
mirror of https://github.com/pragma-/pbot.git synced 2024-10-03 01:48:38 +02:00

FactoidCommands: anybody can now factset and unset action_with_args

This commit is contained in:
Pragmatic Software 2020-01-23 20:53:55 -08:00
parent c0ad02e6a3
commit 9a79d025e9

View File

@ -624,7 +624,7 @@ sub factset {
$mask = $nick;
}
if ((defined $value and $key ne 'action') and lc $mask ne lc $owner and $level == 0) {
if ((defined $value and $key ne 'action' and $key ne 'action_with_args') and lc $mask ne lc $owner and $level == 0) {
return "You are not the owner of $trigger_name.";
}
}
@ -706,7 +706,7 @@ sub factunset {
my ($owner) = $factoid->{'owner'} =~ m/([^!]+)/;
if (lc $nick ne lc $owner and $level == 0) {
if ($key ne 'action_with_args' and lc $nick ne lc $owner and $level == 0) {
return "You are not the owner of $trigger_name.";
}
$oldvalue = $self->{pbot}->{factoids}->{factoids}->{hash}->{$channel}->{$trigger}->{$key};