Skip to content

Commit

Permalink
Fixed pin len check
Browse files Browse the repository at this point in the history
  • Loading branch information
ansxuman committed Nov 30, 2024
1 parent b288848 commit 792cf12
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions services/auth/auth.go
Original file line number Diff line number Diff line change
Expand Up @@ -34,8 +34,8 @@ func (s *Service) HasPin() bool {
}

func (s *Service) SetupPin(pin string) error {
if len(pin) < 4 {
return errors.New("PIN must be at least 4 characters")
if len(pin) < 6 {
return errors.New("PIN must be at least 6 characters")
}
if s.HasPin() {
return errors.New("PIN is already set")
Expand Down

0 comments on commit 792cf12

Please sign in to comment.