Skip to content

Commit

Permalink
documentation tweaks
Browse files Browse the repository at this point in the history
  • Loading branch information
kraih committed May 22, 2013
1 parent 4a5e6c4 commit 518390b
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 5 deletions.
5 changes: 2 additions & 3 deletions lib/Mojo/IOLoop/Delay.pm
Expand Up @@ -38,9 +38,8 @@ sub _step {
$self->{counter} = 0;
if (my $cb = shift @{$self->{steps} ||= []}) { $self->$cb(@args) }

return 0 if $self->{pending};
if ($self->{counter}) { $self->ioloop->timer(0 => $self->begin) }
else { $self->emit(finish => @args) }
if (!$self->{counter}) { $self->emit(finish => @args) }
elsif (!$self->{pending}) { $self->ioloop->timer(0 => $self->begin) }
return 0;
}

Expand Down
4 changes: 2 additions & 2 deletions lib/Mojolicious/Routes.pm
Expand Up @@ -249,9 +249,9 @@ Mojolicious::Routes - Always find your destination with routes!
# More advanced routes
my $blog = $r->under('/blog');
$blog->post('/list')->to('blog#list');
$blog->get('/list')->to('blog#list');
$blog->get('/:id' => [id => qr/\d+/])->to('blog#show', id => 23);
$blog->put(sub { shift->render(text => 'Go away!', status => 405) });
$blog->patch(sub { shift->render(text => 'Go away!', status => 405) });
=head1 DESCRIPTION
Expand Down

0 comments on commit 518390b

Please sign in to comment.