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

Registerable: add unregister_all() subroutine

This commit is contained in:
Pragmatic Software 2020-02-15 07:26:29 -08:00
parent edf735f88a
commit ecd1e4dc86

View File

@ -62,4 +62,9 @@ sub unregister {
@{ $self->{handlers} } = grep { $_ != $ref } @{ $self->{handlers} }; @{ $self->{handlers} } = grep { $_ != $ref } @{ $self->{handlers} };
} }
sub unregister_all {
my ($self) = @_;
$self->{handlers} = [];
}
1; 1;