regex typo
[catagits/Catalyst-Action-REST.git] / 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 {