Skip to content

Commit

Permalink
added another example for error method
Browse files Browse the repository at this point in the history
  • Loading branch information
kraih committed Nov 29, 2014
1 parent ea988d6 commit 39dffc8
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 1 deletion.
2 changes: 1 addition & 1 deletion Changes
@@ -1,5 +1,5 @@

5.68 2014-11-29
5.68 2014-11-30

5.67 2014-11-27
- Improved overall performance by deserializing sessions only on demand.
Expand Down
6 changes: 6 additions & 0 deletions lib/Mojo/Transaction.pm
Expand Up @@ -217,6 +217,12 @@ Connection identifier or socket.
Return transaction error or C<undef> if there is no error, commonly used
together with L</"success">.
# Check for different kinds of errors
if (my $err = $tx->error) {
die "$err->{code} response: $err->{message}" if $err->{code};
die "Connection error: $err->{message}";
}
=head2 is_finished
my $bool = $tx->is_finished;
Expand Down

0 comments on commit 39dffc8

Please sign in to comment.