X-Git-Url: http://wagnertech.de/gitweb/gitweb.cgi/mfinanz.git/blobdiff_plain/75063bf3a632f9d54e2f200cd659724432e0ef82..68ccd089c525fd41d00266fe493cd52a9dbb6513:/SL/DB/BankTransaction.pm diff --git a/SL/DB/BankTransaction.pm b/SL/DB/BankTransaction.pm index 1c2a6dc7f..053abb410 100644 --- a/SL/DB/BankTransaction.pm +++ b/SL/DB/BankTransaction.pm @@ -8,6 +8,7 @@ use strict; use SL::DB::MetaSetup::BankTransaction; use SL::DB::Manager::BankTransaction; use SL::DB::Helper::LinkedRecords; +use Carp; require SL::DB::Invoice; require SL::DB::PurchaseInvoice; @@ -49,7 +50,7 @@ sub linked_invoices { sub get_agreement_with_invoice { my ($self, $invoice) = @_; - die "first argument is not an invoice object" + carp "get_agreement_with_invoice needs an invoice object as its first argument" unless ref($invoice) eq 'SL::DB::Invoice' or ref($invoice) eq 'SL::DB::PurchaseInvoice'; my %points = (