Skip to content
Browse files

allow hashes and hashrefs

  • Loading branch information...
1 parent 1ba96d4 commit c77d637ae9047507b49f7c298f17fa53bddcdcb1 @doy committed
Showing with 2 additions and 2 deletions.
  1. +2 −2 lib/OX/View/TT.pm
View
4 lib/OX/View/TT.pm
@@ -37,8 +37,8 @@ has 'tt' => (
sub _build_template_params {
my ($self, $r, $params) = @_;
return +{
- base => $r->script_name,
- uri_for => sub { $r->uri_for( $_[0] ) },
+ base => $r->script_name,
+ uri_for => sub { $r->uri_for(@_ == 1 ? $_[0] : { @_ }) },
%{ $params || {} }
}
}

0 comments on commit c77d637

Please sign in to comment.
Something went wrong with that request. Please try again.