From 1fc0c16968304b169fb7eb52f162ffa4c7cdc55c Mon Sep 17 00:00:00 2001 From: Yong Tang Date: Fri, 3 Nov 2017 00:20:15 -0700 Subject: Update vendor libraries except client-go, apimachinery and ugorji/go (#1197) This fix updates vendor libraries except client-go, apimachinery and ugorji/go, as github.com/ugorji/go/codec is causing compatibilities issues. Signed-off-by: Yong Tang --- vendor/github.com/go-openapi/spec/items.go | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) (limited to 'vendor/github.com/go-openapi/spec/items.go') diff --git a/vendor/github.com/go-openapi/spec/items.go b/vendor/github.com/go-openapi/spec/items.go index 46944fb69..07ac88e66 100644 --- a/vendor/github.com/go-openapi/spec/items.go +++ b/vendor/github.com/go-openapi/spec/items.go @@ -178,9 +178,14 @@ func (i *Items) UnmarshalJSON(data []byte) error { if err := json.Unmarshal(data, &simpleSchema); err != nil { return err } + var vendorExtensible VendorExtensible + if err := json.Unmarshal(data, &vendorExtensible); err != nil { + return err + } i.Refable = ref i.CommonValidations = validations i.SimpleSchema = simpleSchema + i.VendorExtensible = vendorExtensible return nil } @@ -198,7 +203,11 @@ func (i Items) MarshalJSON() ([]byte, error) { if err != nil { return nil, err } - return swag.ConcatJSON(b3, b1, b2), nil + b4, err := json.Marshal(i.VendorExtensible) + if err != nil { + return nil, err + } + return swag.ConcatJSON(b4, b3, b1, b2), nil } // JSONLookup look up a value by the json property name -- cgit v1.2.3