From: Marius Gavrilescu Date: Sun, 8 Feb 2015 10:43:34 +0000 (+0200) Subject: Improve HTML::Element::fclass X-Git-Url: http://git.ieval.ro/?a=commitdiff_plain;h=28ec8060441f56601f8cb167fafd32fdfb3c1a8a;p=plack-app-gruntmaster.git Improve HTML::Element::fclass --- diff --git a/lib/Plack/App/Gruntmaster/HTML.pm b/lib/Plack/App/Gruntmaster/HTML.pm index fe7e496..81a33c0 100644 --- a/lib/Plack/App/Gruntmaster/HTML.pm +++ b/lib/Plack/App/Gruntmaster/HTML.pm @@ -32,7 +32,7 @@ sub HTML::Element::iter3 { } sub HTML::Element::fid { shift->look_down(id => shift) } -sub HTML::Element::fclass { shift->look_down(class => shift) } +sub HTML::Element::fclass { shift->look_down(class => qr/\b$_[0]\b/) } sub HTML::Element::namedlink { my ($self, $id, $name) = @_;