From: Cinxgler Mariaca Minda Date: Wed, 2 Nov 2011 17:28:29 +0000 (+0000) Subject: regexp test fixed X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;p=catagits%2FCatalystX-HelpText.git regexp test fixed --- diff --git a/lib/CatalystX/HelpText/Finder/TemplateToolkit/Regexp.pm b/lib/CatalystX/HelpText/Finder/TemplateToolkit/Regexp.pm index 58d8e9d..1402b3a 100644 --- a/lib/CatalystX/HelpText/Finder/TemplateToolkit/Regexp.pm +++ b/lib/CatalystX/HelpText/Finder/TemplateToolkit/Regexp.pm @@ -8,7 +8,7 @@ sub find_helptext_keys_in_fn { open(my $FILE, '<', $fn) or warn "Can't open $fn\n" && return; my @keys = (); while (my $line = <$FILE>) { - if (my ($key) = $line =~ m/help_text\(\s*['"](.*)['"]\s*\)/) { + foreach my $key ($line =~ m/help_text\(\s*['"](\w+)['"]\s*\)/g) { push @keys, $key; } }