File Coverage

blib/lib/DTL/Fast/Filter/Striptags.pm
Criterion Covered Total %
statement 17 17 100.0
branch n/a
condition n/a
subroutine 5 5 100.0
pod 0 1 0.0
total 22 23 95.6


line stmt bran cond sub pod time code
1             package DTL::Fast::Filter::Striptags;
2 2     2   778 use strict; use utf8; use warnings FATAL => 'all';
  2     2   2  
  2     2   43  
  2         5  
  2         2  
  2         10  
  2         33  
  2         4  
  2         58  
3 2     2   6 use parent 'DTL::Fast::Filter';
  2         3  
  2         9  
4              
5             $DTL::Fast::FILTER_HANDLERS{'striptags'} = __PACKAGE__;
6              
7             #@Override
8             sub filter
9             {
10 2     2 0 2 shift; # self
11 2         1 shift; # filter_manager
12 2         1 my $value = shift;
13            
14 2         22 $value =~ s/<\/?[^>]+?>//gsi;
15            
16 2         5 return $value;
17             }
18              
19             1;