ZofCMS/Plugin/Sub.pm

filter: Statementstmt 53.3% 8 / 15 Branchbran 0.0% 0 / 4 Conditioncond n/a MC/DCmcdc n/a Subroutinesub 50.0% 2 / 4 Podpod 0.0% 0 / 2 totaltotal 40.0% 10 / 25 CC 3 SCAR 19.0
CC
3
Cov
42%
process
12.0
new
2.0
BEGIN
1.0
CRAP 6.7
« ZofCMS/Plugin/HTMLFactory/PageToBodyId.pm ↑ Summary ZofCMS/Output.pm »
1 package App::ZofCMS::Plugin::Sub;
2  
3 1 ▶use warnings;
Subroutine BEGIN: called CC=1 SCAR=0.0
4 1 ▶use strict;
Subroutine BEGIN: called CC=1 SCAR=0.0
5  
6 1 our $VERSION = '1.001010'; # VERSION
7  
8 0 ▶sub new { bless {}, shift }
Subroutine new: not called CC=1 SCAR=6.9
Pod undocumented
9  
10 0 ▶sub process {
Subroutine process: not called CC=3 SCAR=24.8
Pod undocumented
11 0 my ( $self, $template, $query, $config ) = @_;
12 0 ▶ my $sub = $template->{plug_sub} ? $template->{plug_sub} : $config->conf->{plug_sub};
Branch: 1 branch
BranchTrueFalseTotal
$template->{'plug_sub'} ? : 0 0 0
13 return
14 0 ▶ unless defined $sub;
Branch: 1 branch
BranchTrueFalseTotal
unless defined $sub 0 0 0
15  
16 0 delete $template->{plug_sub};
17 0 delete $config->conf->{plug_sub};
18  
19 0 $sub->( $template, $query, $config );
20 }
21  
22 1 1;
23 __END__
« ZofCMS/Plugin/HTMLFactory/PageToBodyId.pm ↑ Summary ZofCMS/Output.pm »