brainbuffer-go/pkg/brainbuffer/infrastructure/errors/errors.go
2022-06-03 23:44:08 +06:00

29 lines
418 B
Go

package errors
type UnknownError struct {
Err error
}
func (err UnknownError) Error() string {
return err.Err.Error()
}
func (err UnknownError) Unwrap() error {
return err.Err
}
type NotFoundError struct {
Message string
}
func (err NotFoundError) Error() string {
return err.Message
}
type AlreadyExistsError struct {
Message string
}
func (err AlreadyExistsError) Error() string {
return err.Message
}