Skip to content

Commit

Permalink
transaction does not change here
Browse files Browse the repository at this point in the history
  • Loading branch information
kraih committed Jul 12, 2014
1 parent 72515bc commit e76abdb
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions lib/Mojo/UserAgent.pm
Expand Up @@ -223,7 +223,7 @@ sub _enqueue {
my $queue = $self->{$nb ? 'nb_queue' : 'queue'} ||= [];
my $max = $self->max_connections;
$self->_remove(shift(@$queue)->[1]) while @$queue && @$queue >= $max;
$max ? push(@$queue, [$name, $id]) : $self->_loop($nb)->stream($id)->close;
$max ? push @$queue, [$name, $id] : $self->_loop($nb)->stream($id)->close;
}

sub _error {
Expand Down Expand Up @@ -275,8 +275,8 @@ sub _read {
# Process incoming data
warn "-- Client <<< Server (@{[$tx->req->url->to_abs]})\n$chunk\n" if DEBUG;
$tx->client_read($chunk);
if ($tx->is_finished) { $self->_finish($id) }
elsif ($c->{tx}->is_writing) { $self->_write($id) }
if ($tx->is_finished) { $self->_finish($id) }
elsif ($tx->is_writing) { $self->_write($id) }
}

sub _redirect {
Expand Down

0 comments on commit e76abdb

Please sign in to comment.