Skip to content

Commit

Permalink
bridge->under
Browse files Browse the repository at this point in the history
  • Loading branch information
Brian Duggan committed Feb 26, 2015
1 parent c616e55 commit 0ad50e0
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions lib/Tuba.pm
Original file line number Diff line number Diff line change
Expand Up @@ -213,12 +213,12 @@ sub startup {
$resource->get("*$identifier" => \@restrict => \%defaults )->over(not_match => { $identifier => $reserved })->to('#show')->name("show_$name");
} else {
$resource->get(":$identifier" => \@restrict => \%defaults )->to('#show')->name("show_$name");
$select = $resource->bridge(":$identifier")->to('#select')->name("select_$name");
$select = $resource->under(":$identifier")->to('#select')->name("select_$name");
}

return $select if $config->{read_only};

my $authed = $r->bridge("/$path_base")->to(cb => sub {
my $authed = $r->under("/$path_base")->to(cb => sub {
my $c = shift;
return $c->deny_auth unless $c->auth && $c->authz(role => 'update');
return 1;
Expand Down Expand Up @@ -373,7 +373,7 @@ sub startup {
my $reference = $r->resource('reference');
$report->get('/reference')->to('reference#list');
$r->lookup('authed_select_reference')->post('/match')->to('reference#smartmatch') unless $config->{read_only};
$r->bridge('/reference/match')
$r->under('/reference/match')
->to(cb => sub {
my $c = shift;
return $c->deny_auth unless $c->auth && $c->authz(role => 'update');
Expand Down Expand Up @@ -446,7 +446,7 @@ sub startup {
$r->get('/autocomplete')->to('search#autocomplete');

unless ($config->{read_only}) {
my $authed = $r->bridge->to(
my $authed = $r->under->to(
cb => sub {
my $c = shift;
return $c->deny_auth unless $c->auth && $c->authz(role => 'update');
Expand Down

0 comments on commit 0ad50e0

Please sign in to comment.