regex typo
nebulous [Mon, 11 Jan 2010 18:32:16 +0000 (13:32 -0500)]
lib/Catalyst/Action/Serialize/JSONP.pm

index 4354ce2..705a5da 100644 (file)
@@ -15,7 +15,7 @@ after 'execute' => sub {
 
   my $callback_value = $c->req->param($callback_key);
   if ($callback_value) {
-    if ($callback_value =~ /^\w+/) {
+    if ($callback_value =~ /^\w+$/) {
       $c->res->content_type('text/javascript');
       $c->res->output($callback_value.'('.$c->res->output().');');
     } else {