mirror of
https://github.com/invoiceninja/invoiceninja.git
synced 2025-05-24 02:14:21 -04:00
Different way to access transaction via expense
This commit is contained in:
parent
eebdf02874
commit
8ef96a3f55
@ -103,7 +103,7 @@ class ExpenseRepository extends BaseRepository
|
||||
public function delete($expense) :Expense
|
||||
{
|
||||
|
||||
if ($expense->transaction_id) {
|
||||
if ($expense->transaction()->exists()) {
|
||||
|
||||
$exp_ids = collect(explode(',', $expense->transaction->expense_id))->filter(function ($id) use ($expense) {
|
||||
return $id != $expense->hashed_id;
|
||||
|
Loading…
x
Reference in New Issue
Block a user