Skip to content

Commit

Permalink
minor update
Browse files Browse the repository at this point in the history
  • Loading branch information
tejal29 committed Nov 30, 2020
1 parent f9338bc commit 75862c2
Showing 1 changed file with 4 additions and 7 deletions.
11 changes: 4 additions & 7 deletions pkg/skaffold/errors/err_def.go
Original file line number Diff line number Diff line change
Expand Up @@ -48,16 +48,17 @@ func (e ErrDef) Error() string {

func (e ErrDef) Unwrap() error {
return e.err
=======
}

type ErrDef struct {
ae proto.ActionableErr
}

func (e ErrDef) Error() string {
return fmt.Sprintf("%s. %s", e.ae.Message, concatSuggestions(e.Suggestions()))
>>>>>>> c0434f6aa (add tests)
if s := concatSuggestions(e.Suggestions()); s != "" {
return fmt.Sprintf("%s. %s", e.ae.Message, concatSuggestions(e.Suggestions()))
}
return e.ae.Message
}

func (e ErrDef) StatusCode() proto.StatusCode {
Expand All @@ -68,7 +69,6 @@ func (e ErrDef) Suggestions() []*proto.Suggestion {
return e.ae.Suggestions
}

<<<<<<< HEAD
func NewError(err error, ae proto.ActionableErr) ErrDef {
return ErrDef{
err: err,
Expand All @@ -77,9 +77,6 @@ func NewError(err error, ae proto.ActionableErr) ErrDef {
}

func NewErrorWithStatusCode(ae proto.ActionableErr) ErrDef {
=======
func NewError(ae proto.ActionableErr) ErrDef {
>>>>>>> c0434f6aa (add tests)
return ErrDef{
ae: ae,
}
Expand Down

0 comments on commit 75862c2

Please sign in to comment.