Skip to content

Commit

Permalink
fix(store): nil-error for buddy
Browse files Browse the repository at this point in the history
  • Loading branch information
MunifTanjim committed Nov 27, 2024
1 parent 5243279 commit 1d597ab
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions internal/buddy/response.go
Original file line number Diff line number Diff line change
Expand Up @@ -25,10 +25,13 @@ type Response[T interface{}] struct {
}

type ResponseEnvelop interface {
GetError() *ResponseError
GetError() error
}

func (r Response[any]) GetError() *ResponseError {
func (r Response[any]) GetError() error {
if r.Error == nil {
return nil
}
return r.Error
}

Expand Down

0 comments on commit 1d597ab

Please sign in to comment.