Skip to content

Commit

Permalink
fixed delay example
Browse files Browse the repository at this point in the history
  • Loading branch information
kraih committed Oct 28, 2011
1 parent 1aa7665 commit 74f462b
Show file tree
Hide file tree
Showing 4 changed files with 3 additions and 6 deletions.
2 changes: 1 addition & 1 deletion lib/Mojo/IOLoop.pm
Expand Up @@ -673,7 +673,7 @@ Note that this method is EXPERIMENTAL and might change without warning!
my $delay = $loop->delay;
my $delay = $loop->delay(sub {...});
Get L<Mojo::IOLoop::Delay> event synchronization helper.
Get L<Mojo::IOLoop::Delay> object to help synchronizing events.
Note that this method is EXPERIMENTAL and might change without warning!
# Synchronize multiple events
Expand Down
3 changes: 1 addition & 2 deletions lib/Mojo/IOLoop/Delay.pm
Expand Up @@ -52,8 +52,7 @@ Mojo::IOLoop::Delay - IOLoop delay
=head1 DESCRIPTION
L<Mojo::IOLoop::Delay> is an event synchronization helper for
L<Mojo::IOLoop>.
L<Mojo::IOLoop::Delay> synchronizes events for L<Mojo::IOLoop>.
Note that this module is EXPERIMENTAL and might change without warning!
=head1 EVENTS
Expand Down
2 changes: 0 additions & 2 deletions lib/Mojo/IOWatcher/EV.pm
Expand Up @@ -110,8 +110,6 @@ Construct a new L<Mojo::IOWatcher::EV> object.
Change I/O events to watch handle for.
$watcher->change($handle, 0, 0);
=head2 C<drop_handle>
$watcher->drop_handle($handle);
Expand Down
2 changes: 1 addition & 1 deletion lib/Mojolicious/Guides/Cookbook.pod
Expand Up @@ -441,7 +441,7 @@ synchronize multiple non-blocking requests.
my $delay = Mojo::IOLoop->delay;
$ua->get('http://mojolicio.us' => $delay->begin);
$ua->get('http://mojolicio.us/perldoc' => $delay->begin);
my ($tx, $tx2) = $t->wait;
my ($tx, $tx2) = $delay->wait;

Just be aware that the resulting transactions will be in random order.

Expand Down

0 comments on commit 74f462b

Please sign in to comment.