Skip to content

Instantly share code, notes, and snippets.

Created November 5, 2014 18:28
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save anonymous/cc76e0ec40c31045d43a to your computer and use it in GitHub Desktop.
Save anonymous/cc76e0ec40c31045d43a to your computer and use it in GitHub Desktop.
diff --git a/lib/Mojo/IOLoop.pm b/lib/Mojo/IOLoop.pm
index 118bd05..04b355e 100644
--- a/lib/Mojo/IOLoop.pm
+++ b/lib/Mojo/IOLoop.pm
@@ -71,7 +71,7 @@ sub client {
$client->on(
error => sub {
$self->_remove($id);
- $self->$cb(pop, undef);
+ $self->$cb(pop || 'Unknown error', undef);
}
);
$client->connect(@_);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment