Skip to content

Commit

Permalink
fixed bug where match attribute was not hidden from the router
Browse files Browse the repository at this point in the history
  • Loading branch information
kraih committed Jun 9, 2013
1 parent cb5822b commit 60059ca
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 5 deletions.
3 changes: 2 additions & 1 deletion Changes
@@ -1,7 +1,8 @@

4.14 2013-06-10
- Improved url_for performance slightly.
- Fixed bug where render_later method was not hidden from the router.
- Fixed bug where match attribute and render_later method were not hidden
from the router.

4.13 2013-06-09
- Replaced ua method in Mojolicious::Controller with a helper.
Expand Down
9 changes: 5 additions & 4 deletions lib/Mojolicious.pm
Expand Up @@ -69,10 +69,11 @@ sub new {
my $r = $self->routes->namespaces([ref $self]);

# Hide controller attributes/methods and "handler"
$r->hide(qw(AUTOLOAD DESTROY app cookie finish flash handler on param));
$r->hide(qw(redirect_to render render_exception render_later render_maybe));
$r->hide(qw(render_not_found render_static rendered req res respond_to));
$r->hide(qw(send session signed_cookie stash tx url_for write write_chunk));
$r->hide(qw(AUTOLOAD DESTROY app cookie finish flash handler match on));
$r->hide(qw(param redirect_to render render_exception render_later));
$r->hide(qw(render_maybe render_not_found render_static rendered req res));
$r->hide(qw(respond_to send session signed_cookie stash tx url_for write));
$r->hide(qw(write_chunk));

# Check if we have a log directory
my $mode = $self->mode;
Expand Down
1 change: 1 addition & 0 deletions t/mojolicious/app.t
Expand Up @@ -75,6 +75,7 @@ ok $t->app->routes->is_hidden('finish'), 'is hidden';
ok $t->app->routes->is_hidden('flash'), 'is hidden';
ok $t->app->routes->is_hidden('handler'), 'is hidden';
ok $t->app->routes->is_hidden('has'), 'is hidden';
ok $t->app->routes->is_hidden('match'), 'is hidden';
ok $t->app->routes->is_hidden('new'), 'is hidden';
ok $t->app->routes->is_hidden('on'), 'is hidden';
ok $t->app->routes->is_hidden('param'), 'is hidden';
Expand Down

0 comments on commit 60059ca

Please sign in to comment.