| 1 | package HTTP::Balancer::Command::Del::Backend; | ||||||||||
| 2 | 1 | ▶ | use Modern::Perl; | ||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||
| 3 | 1 | ▶ | use Moose; | ||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||
| 4 | 1 | with qw(HTTP::Balancer::Role::Command); | |||||||||
| 5 | |||||||||||
| 6 | has name => ( | ||||||||||
| 7 | is => "rw", | ||||||||||
| 8 | traits => [ 'NoGetopt' ], | ||||||||||
| 9 | 0 | ▶ | default => sub { shift->argv(2) }, | ||||||||
|
Subroutine
__ANON__: not called CC=1 SCAR=6.9
| |||||||||||
| 10 | 1 | ); | |||||||||
| 11 | |||||||||||
| 12 | 0 | ▶ | sub ordinary_args { | ||||||||
|
Subroutine
ordinary_args: not called CC=1 SCAR=6.9
Pod
undocumented
| |||||||||||
| 13 | 0 | qw(name); | |||||||||
| 14 | } | ||||||||||
| 15 | |||||||||||
| 16 | 0 | ▶ | sub run { | ||||||||
|
Subroutine
run: not called CC=2 SCAR=17.9
Pod
undocumented
| |||||||||||
| 17 | 0 | my ($self, ) = @_; | |||||||||
| 18 | |||||||||||
| 19 | 0 | my $backend = $self->model("Backend")->find(name => $self->name); | |||||||||
| 20 | 0 | ▶ | $backend ? $backend->remove : say "not found"; | ||||||||
|
Branch: 1 branch
| |||||||||||
| 21 | } | ||||||||||
| 22 | |||||||||||
| 23 | |||||||||||
| 24 | 1 | 1; | |||||||||