| 1 | package Lemonldap::NG::Handler::Main::MsgActions; | ||||||||||
| 2 | |||||||||||
| 3 | 29 | ▶ | use strict; | ||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||
| 4 | 29 | ▶ | use Exporter 'import'; | ||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||
| 5 | |||||||||||
| 6 | 29 | our @EXPORT = qw(msgActions addMsgAction delMsgAction); | |||||||||
| 7 | |||||||||||
| 8 | our $msgActions = { | ||||||||||
| 9 | 15 | ▶ | newConf => sub { | ||||||||
|
Subroutine
__ANON__: called CC=2 SCAR=6.9
| |||||||||||
| 10 | 15 | my ( $class, $msg, $req ) = @_; | |||||||||
| 11 | 15 | ▶ | unless ( $class->checkConf() ) { | ||||||||
|
Branch: 1 branch
| |||||||||||
| 12 | 1 | $class->logger->error("$class: No configuration found"); | |||||||||
| 13 | 1 | $req->data->{noTry} = 1; | |||||||||
| 14 | } | ||||||||||
| 15 | }, | ||||||||||
| 16 | 0 | ▶ | unlog => sub { | ||||||||
|
Subroutine
__ANON__: not called CC=1 SCAR=6.9
| |||||||||||
| 17 | 0 | my ( $class, $msg, $req ) = @_; | |||||||||
| 18 | 0 | $class->localUnlog( $req, $msg->{id} ); | |||||||||
| 19 | }, | ||||||||||
| 20 | 29 | }; | |||||||||
| 21 | |||||||||||
| 22 | 15 | ▶ | sub msgActions { return $msgActions } | ||||||||
|
Subroutine
msgActions: called CC=1 SCAR=0.0
Pod
undocumented
| |||||||||||
| 23 | |||||||||||
| 24 | 0 | ▶ | sub addMsgAction { | ||||||||
|
Subroutine
addMsgAction: not called CC=1 SCAR=6.9
Pod
undocumented
| |||||||||||
| 25 | 0 | my ( $name, $sub ) = @_; | |||||||||
| 26 | 0 | $msgActions->{$name} = $sub; | |||||||||
| 27 | } | ||||||||||
| 28 | |||||||||||
| 29 | 0 | ▶ | sub delMsgAction { | ||||||||
|
Subroutine
delMsgAction: not called CC=1 SCAR=6.9
Pod
undocumented
| |||||||||||
| 30 | 0 | my ($name) = @_; | |||||||||
| 31 | 0 | delete $msgActions->{$name}; | |||||||||
| 32 | } | ||||||||||
| 33 | |||||||||||
| 34 | 29 | 1; | |||||||||