fix godoc for IsZero

it had the old behavior from v2
This commit is contained in:
Greg 2016-02-28 09:32:36 +09:00
parent 79c5bd36b6
commit aa8aa51503
2 changed files with 2 additions and 3 deletions

View file

@ -95,8 +95,7 @@ func (s String) Ptr() *string {
return &s.String
}
// IsZero returns true for null or empty strings, for future omitempty support. (Go 1.4?)
// Will return false s if blank but non-null.
// IsZero returns true for null strings, for potential future omitempty support.
func (s String) IsZero() bool {
return !s.Valid
}

View file

@ -97,7 +97,7 @@ func (s String) Ptr() *string {
return &s.String
}
// IsZero returns true for null or empty strings, for future omitempty support. (Go 1.4?)
// IsZero returns true for null or empty strings, for potential future omitempty support.
func (s String) IsZero() bool {
return !s.Valid || s.String == ""
}