File Coverage

blib/lib/DTL/Fast/Filter/Escape.pm
Criterion Covered Total %
statement 15 15 100.0
branch n/a
condition n/a
subroutine 5 5 100.0
pod 0 1 0.0
total 20 21 95.2


line stmt bran cond sub pod time code
1             package DTL::Fast::Filter::Escape;
2 5     5   2962 use strict; use utf8; use warnings FATAL => 'all';
  5     5   11  
  5     5   118  
  5         24  
  5         10  
  5         25  
  5         128  
  5         9  
  5         162  
3 5     5   24 use parent 'DTL::Fast::Filter';
  5         9  
  5         30  
4              
5             $DTL::Fast::FILTER_HANDLERS{'escape'} = __PACKAGE__;
6             $DTL::Fast::FILTER_HANDLERS{'force_escape'} = __PACKAGE__;
7              
8             #@Override
9             sub filter
10             {
11 8     8 0 12 shift; # self
12 8         15 shift->{'safe'} = 1; # filter_manager
13 8         60 return DTL::Fast::html_protect(shift);
14             }
15              
16             1;