diff options
-rw-r--r-- | LedgerSMB/DBObject.pm | 3 | ||||
-rw-r--r-- | LedgerSMB/Form.pm | 2 |
2 files changed, 3 insertions, 2 deletions
diff --git a/LedgerSMB/DBObject.pm b/LedgerSMB/DBObject.pm index 6d298ecb..f3094dff 100644 --- a/LedgerSMB/DBObject.pm +++ b/LedgerSMB/DBObject.pm @@ -1,4 +1,5 @@ + =head1 NAME LedgerSMB::DBObject - LedgerSMB class for building objects from db relations @@ -158,7 +159,7 @@ sub run_custom_queries { if ( $query_type eq 'UPDATE' ) { $query = "DELETE FROM $_ WHERE row_id = ?"; my $sth = $dbh->prepare($query); - $sth->execute->( $self->{ "id" . "$linenum" } ) + $sth->execute( $self->{ "id" . "$linenum" } ) || $self->dberror($query); } elsif ( $query_type eq 'INSERT' ) { diff --git a/LedgerSMB/Form.pm b/LedgerSMB/Form.pm index 206669c6..09278953 100644 --- a/LedgerSMB/Form.pm +++ b/LedgerSMB/Form.pm @@ -1514,7 +1514,7 @@ sub run_custom_queries { if ( $query_type eq 'UPDATE' ) { $query = "DELETE FROM $_ WHERE row_id = ?"; my $sth = $dbh->prepare($query); - $sth->execute->( $self->{ "id" . "$linenum" } ) + $sth->execute( $self->{ "id" . "$linenum" } ) || $self->dberror($query); } elsif ( $query_type eq 'INSERT' ) { |