Permalink
Browse files

Merge pull request #23 from duckduckgo/dylan/duplicate-req-process-fix

ensure top level req before processing query
  • Loading branch information...
2 parents 8a66e83 + fa24bf9 commit 8aee863d8e6874aee9bee05611806ce8f3b8dc97 @moollaza moollaza committed Oct 7, 2013
Showing with 1 addition and 1 deletion.
  1. +1 −1 lib/App/DuckPAN/Web.pm
View
@@ -158,7 +158,7 @@ sub request {
} elsif ($request->param('duckduckhack_js')) {
$response->content_type('text/javascript');
$body = $self->page_js;
- } elsif ($request->param('q')) {
+ } elsif ($request->param('q') && $request->path_info eq '/') {
my $query = $request->param('q');
Encode::_utf8_on($query);
my $ddg_request = DDG::Request->new(

0 comments on commit 8aee863

Please sign in to comment.