summaryrefslogtreecommitdiff
path: root/vendor/github.com/gin-gonic/gin/errors.go
diff options
context:
space:
mode:
Diffstat (limited to 'vendor/github.com/gin-gonic/gin/errors.go')
-rw-r--r--vendor/github.com/gin-gonic/gin/errors.go11
1 files changed, 6 insertions, 5 deletions
diff --git a/vendor/github.com/gin-gonic/gin/errors.go b/vendor/github.com/gin-gonic/gin/errors.go
index 2853ce8ed..06b53c28b 100644
--- a/vendor/github.com/gin-gonic/gin/errors.go
+++ b/vendor/github.com/gin-gonic/gin/errors.go
@@ -39,7 +39,7 @@ type Error struct {
type errorMsgs []*Error
-var _ error = &Error{}
+var _ error = (*Error)(nil)
// SetType sets the error's type.
func (msg *Error) SetType(flags ErrorType) *Error {
@@ -124,10 +124,11 @@ func (a errorMsgs) Last() *Error {
// Errors returns an array with all the error messages.
// Example:
-// c.Error(errors.New("first"))
-// c.Error(errors.New("second"))
-// c.Error(errors.New("third"))
-// c.Errors.Errors() // == []string{"first", "second", "third"}
+//
+// c.Error(errors.New("first"))
+// c.Error(errors.New("second"))
+// c.Error(errors.New("third"))
+// c.Errors.Errors() // == []string{"first", "second", "third"}
func (a errorMsgs) Errors() []string {
if len(a) == 0 {
return nil