diff --git a/service/service.go b/service/service.go index 6d43c33..5c40c6e 100644 --- a/service/service.go +++ b/service/service.go @@ -1 +1,5 @@ package service + +import "forge.capytal.company/capytalcode/project-comicverse/repository" + +var ErrNotFound = repository.ErrNotFound diff --git a/service/user.go b/service/user.go index ab0f1ea..3766a76 100644 --- a/service/user.go +++ b/service/user.go @@ -88,8 +88,7 @@ func (svc *User) Login(username, password string) (user model.User, err error) { } var ( - ErrAlreadyExists = errors.New("model already exists") - ErrNotFound = repository.ErrNotFound - ErrPasswordTooLong = bcrypt.ErrPasswordTooLong - ErrIncorrectPassword = bcrypt.ErrMismatchedHashAndPassword + ErrUsernameAlreadyExists = errors.New("service: username already exists") + ErrPasswordTooLong = bcrypt.ErrPasswordTooLong + ErrIncorrectPassword = bcrypt.ErrMismatchedHashAndPassword )