From 22113b75c7c5e13fd98471a226a097c50b6aa7d0 Mon Sep 17 00:00:00 2001 From: merdan Date: Fri, 1 Apr 2022 15:52:13 +0500 Subject: [PATCH] groupby color --- packages/Sarga/API/Http/Controllers/Checkout.php | 2 +- packages/Sarga/API/Http/Resources/Catalog/Attribute.php | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/packages/Sarga/API/Http/Controllers/Checkout.php b/packages/Sarga/API/Http/Controllers/Checkout.php index 65c059918..3ff593036 100644 --- a/packages/Sarga/API/Http/Controllers/Checkout.php +++ b/packages/Sarga/API/Http/Controllers/Checkout.php @@ -84,7 +84,7 @@ class Checkout extends CheckoutController if (Cart::hasError() || ! $payment || ! Cart::savePaymentMethod($payment)) { return response([ 'success' => false, - 'message' => 'Payment unsuccessfull' + 'message' => 'Payment unsuccessful' ],400); } diff --git a/packages/Sarga/API/Http/Resources/Catalog/Attribute.php b/packages/Sarga/API/Http/Resources/Catalog/Attribute.php index 4a4949240..83ec310f2 100644 --- a/packages/Sarga/API/Http/Resources/Catalog/Attribute.php +++ b/packages/Sarga/API/Http/Resources/Catalog/Attribute.php @@ -17,7 +17,7 @@ class Attribute extends JsonResource return [ 'id' => $this->id, 'code' => $this->code, - 'name' => $this->name, + 'name' => $this->name ?? $this->admin_name, 'options' => AttributeOption::collection($this->options), ]; }