Catmandu/Fix/remove_field.pm

filter: Statementstmt 100% 21 / 21 Branchbran n/a Conditioncond n/a MC/DCmcdc n/a Subroutinesub 100% 6 / 6 Podpod n/a totaltotal 100% 27 / 27 CC 1 SCAR 0.0
CC
1
Cov
100%
BEGIN
1.0
BEGIN
1.0
BEGIN
1.0
CRAP 1.0
« Catmandu/Fix/remove.pm ↑ Summary Catmandu/Fix/replace_all.pm »
1 package Catmandu::Fix::remove_field;
2  
3 5 ▶use Catmandu::Sane;
Subroutine BEGIN: called CC=1 SCAR=0.0
4  
5 5 our $VERSION = '1.2025';
6  
7 5 ▶use Moo;
Subroutine BEGIN: called CC=1 SCAR=0.0
8 5 ▶use Catmandu::Util::Path qw(as_path);
Subroutine BEGIN: called CC=1 SCAR=0.0
9 5 ▶use namespace::clean;
Subroutine BEGIN: called CC=1 SCAR=0.0
10 5 ▶use Catmandu::Fix::Has;
Subroutine BEGIN: called CC=1 SCAR=0.0
11  
12 5 with 'Catmandu::Fix::Builder';
13  
14 5 has path => (fix_arg => 1);
15  
16 12 ▶sub _build_fixer {
Subroutine _build_fixer: called CC=1 SCAR=0.0
17 12 my ($self) = @_;
18 12 as_path($self->path)->deleter;
19 }
20  
21 5 1;
22  
23 __END__
« Catmandu/Fix/remove.pm ↑ Summary Catmandu/Fix/replace_all.pm »