From fbb5a8bbc8cb9667852fe1e99d544628c840eb89 Mon Sep 17 00:00:00 2001 From: Hillel Coren Date: Sun, 1 Jan 2017 20:54:43 +0200 Subject: [PATCH] Fix for tests --- app/Listeners/ActivityListener.php | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/app/Listeners/ActivityListener.php b/app/Listeners/ActivityListener.php index 6c7b1d125ce9..c2e60b0d587c 100644 --- a/app/Listeners/ActivityListener.php +++ b/app/Listeners/ActivityListener.php @@ -128,7 +128,7 @@ class ActivityListener public function updatedInvoice(InvoiceWasUpdated $event) { $backupInvoice = Invoice::with('invoice_items', 'client.account', 'client.contacts') - ->withArchived() + ->withTrashed() ->find($event->invoice->id); $activity = $this->activityRepo->create( @@ -234,7 +234,9 @@ class ActivityListener return; } - $backupQuote = Invoice::with('invoice_items', 'client.account', 'client.contacts')->find($event->quote->id); + $backupQuote = Invoice::with('invoice_items', 'client.account', 'client.contacts') + ->withTrashed() + ->find($event->quote->id); $activity = $this->activityRepo->create( $event->quote,