X-Git-Url: http://wagnertech.de/git?a=blobdiff_plain;f=SL%2FDB.pm;h=29d0090ca2de1fe0e2bfde5d640ee92664a70fa7;hb=e476a9df6d7b8794add9fe384a624817dc21c21b;hp=40c8a9596a06541fd37a30d55df6542545ab08cb;hpb=660c7e5312f7fae7766b731f7001e5e8197c6887;p=kivitendo-erp.git diff --git a/SL/DB.pm b/SL/DB.pm index 40c8a9596..29d0090ca 100644 --- a/SL/DB.pm +++ b/SL/DB.pm @@ -7,6 +7,7 @@ use Data::Dumper; use English qw(-no_match_vars); use Rose::DB; use Rose::DBx::Cache::Anywhere; +use Scalar::Util qw(blessed); use base qw(Rose::DB); @@ -138,7 +139,7 @@ sub with_transaction { : $self->do_transaction(sub { $result = $code->(@args) }); } or do { my $error = $self->error; - if (ref $error) { + if (blessed $error) { if ($error->isa('SL::X::DBError')) { # gobble the exception } else {