From 7915ed8e8abbc906f0fdbb278313fc210df6fc3c Mon Sep 17 00:00:00 2001 From: Arman Date: Mon, 6 Aug 2018 16:05:14 +0700 Subject: [PATCH] Omitempty for key in customer detail --- request.go | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/request.go b/request.go index d64f02d..a80b10a 100644 --- a/request.go +++ b/request.go @@ -22,13 +22,13 @@ type CustAddress struct { // CustDetail : Represent the customer detail type CustDetail struct { // first name - FName string `json:"first_name"` + FName string `json:"first_name,omitempty"` // last name - LName string `json:"last_name"` + LName string `json:"last_name,omitempty"` - Email string `json:"email"` - Phone string `json:"phone"` + Email string `json:"email,omitempty"` + Phone string `json:"phone,omitempty"` BillAddr *CustAddress `json:"billing_address,omitempty"` ShipAddr *CustAddress `json:"customer_address,omitempty"` }