From e441182b96b6286ff9d59ab807c57c1db03215da Mon Sep 17 00:00:00 2001 From: Remi Jannel Date: Fri, 19 Feb 2021 11:56:03 -0800 Subject: [PATCH] Fix `LineItemTax` to deserialie `Rate` properly --- lineitem.go | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/lineitem.go b/lineitem.go index 507af72eb9..b2fd22c803 100644 --- a/lineitem.go +++ b/lineitem.go @@ -12,7 +12,11 @@ type LineItemDiscount struct { // LineItemTax represent the details of one tax rate applied to a line item. type LineItemTax struct { - Amount int64 `json:"amount"` + Amount int64 `json:"amount"` + Rate *TaxRate `json:"rate"` + + // This property never worked. Use Rate instead. + // TODO: Remove in the next major version TaxRate *TaxRate `json:"tax_rate"` }