Skip to content

Commit

Permalink
just recommend the over method
Browse files Browse the repository at this point in the history
  • Loading branch information
kraih committed Jan 30, 2017
1 parent 084cc33 commit fea34d7
Showing 1 changed file with 1 addition and 6 deletions.
7 changes: 1 addition & 6 deletions lib/Mojolicious/Guides/Routing.pod
Expand Up @@ -720,11 +720,6 @@ constructs.
# http://mojolicious.org/perldoc
$r->get('/perldoc')->over(host => 'mojolicious.org')->to('perldoc#index');

Or append your conditions as key/value pairs to the route.

# / (Origin: http://perl.org)
$r->get('/' => agent => qr/Firefox/)->to('foo#bar');

Just be aware that conditions are too complex for the routing cache, which
normally speeds up recurring requests, and can therefore reduce performance.

Expand Down Expand Up @@ -919,7 +914,7 @@ Use whatever request information you need.
});

# /hello?to=world&test=1
$r->get('/hello' => query => {test => 1, to => 'world'})->to('foo#bar');
$r->get('/hello')->over(query => {test => 1, to => 'world'})->to('foo#bar');

=head2 Condition plugins

Expand Down

0 comments on commit fea34d7

Please sign in to comment.