fix(onboarding): could not create user (#848)

fix: onboarding not working
This commit is contained in:
ze0s 2023-04-17 20:56:17 +02:00 committed by GitHub
parent d03561d61c
commit 7f05dd1efd
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
16 changed files with 182 additions and 130 deletions

View file

@ -5,7 +5,7 @@ import "context"
type UserRepo interface {
GetUserCount(ctx context.Context) (int, error)
FindByUsername(ctx context.Context, username string) (*User, error)
Store(ctx context.Context, user User) error
Store(ctx context.Context, req CreateUserRequest) error
Update(ctx context.Context, user User) error
}
@ -14,3 +14,8 @@ type User struct {
Username string `json:"username"`
Password string `json:"password"`
}
type CreateUserRequest struct {
Username string `json:"username"`
Password string `json:"password"`
}