From f328403701d440e7155de1a88ea003c2a5d7e50b Mon Sep 17 00:00:00 2001 From: Darren Shepherd Date: Mon, 1 Jan 2018 22:12:48 -0700 Subject: [PATCH] Update vendor --- vendor.conf | 2 +- vendor/github.com/rancher/norman/types/convert/convert.go | 5 ++++- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/vendor.conf b/vendor.conf index 359f398a..e583ceda 100644 --- a/vendor.conf +++ b/vendor.conf @@ -3,5 +3,5 @@ github.com/rancher/types k8s.io/kubernetes v1.8.3 transitive=true,staging=true bitbucket.org/ww/goautoneg a547fc61f48d567d5b4ec6f8aee5573d8efce11d https://github.com/rancher/goautoneg.git -github.com/rancher/norman b80039523f49e7bfd335031ac82208f1bbf6bd40 +github.com/rancher/norman c94e18869aa8779706235e42263aeadd754e7752 golang.org/x/sync fd80eb99c8f653c847d294a001bdf2a3a6f768f5 diff --git a/vendor/github.com/rancher/norman/types/convert/convert.go b/vendor/github.com/rancher/norman/types/convert/convert.go index 98b2a985..43ba4774 100644 --- a/vendor/github.com/rancher/norman/types/convert/convert.go +++ b/vendor/github.com/rancher/norman/types/convert/convert.go @@ -27,6 +27,9 @@ func Singular(value interface{}) interface{} { } func ToString(value interface{}) string { + if t, ok := value.(time.Time); ok { + return t.Format(time.RFC3339) + } single := Singular(value) if single == nil { return "" @@ -37,7 +40,7 @@ func ToString(value interface{}) string { func ToTimestamp(value interface{}) (int64, error) { str := ToString(value) if str == "" { - return 0, errors.New("Invalid date") + return 0, errors.New("invalid date") } t, err := time.Parse(time.RFC3339, str) if err != nil {