зеркало из https://github.com/mozilla/pjs.git
labels can only go on blocks, not if statements, apparently. fixes bug 139646
This commit is contained in:
Родитель
838efb60bc
Коммит
88136213bb
|
@ -263,13 +263,15 @@ sub SetFactoid {
|
|||
my($event, $replace, $subject, $database, $add, $object, $direct, $fromBot) = @_;
|
||||
if ($direct or $self->allowed($event, 'Learn')) {
|
||||
|
||||
teacher: if (@{$self->{'teachers'}}) {
|
||||
foreach my $user (@{$self->{'teachers'}}) {
|
||||
if ($user eq $event->{'userName'}) {
|
||||
last teacher;
|
||||
teacher: {
|
||||
if (@{$self->{'teachers'}}) {
|
||||
foreach my $user (@{$self->{'teachers'}}) {
|
||||
if ($user eq $event->{'userName'}) {
|
||||
last teacher;
|
||||
}
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
|
||||
# update the database
|
||||
|
|
Загрузка…
Ссылка в новой задаче