From c0d781daa6a2c88b811be2dabe6f6f65d2042d32 Mon Sep 17 00:00:00 2001 From: David Bomba Date: Fri, 12 Aug 2022 09:38:48 +1000 Subject: [PATCH] Fixes for editing an archived gateway --- app/Models/CompanyGateway.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/app/Models/CompanyGateway.php b/app/Models/CompanyGateway.php index 0942bbf6bcc4..f668d8423f2a 100644 --- a/app/Models/CompanyGateway.php +++ b/app/Models/CompanyGateway.php @@ -413,8 +413,9 @@ class CompanyGateway extends BaseModel public function resolveRouteBinding($value, $field = null) { + return $this - ->where('id', $this->decodePrimaryKey($value))->firstOrFail(); + ->where('id', $this->decodePrimaryKey($value))->withTrashed()->firstOrFail(); }