Skip to content

Commit

Permalink
Merge pull request c9s#533 from c9s/telegram-auth-message
Browse files Browse the repository at this point in the history
refine auth message
  • Loading branch information
c9s authored Apr 16, 2022
2 parents cb45006 + 38dfa32 commit 8ba0b8c
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion pkg/interact/auth.go
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,13 @@ func (it *AuthInteract) Commands(interact *Interact) {
})
} else {
interact.Command("/auth", "authorize", func(reply Reply) error {
reply.Message("Enter your authentication code")
switch it.Mode {
case AuthModeToken:
reply.Message("Enter your authentication token")

case AuthModeOTP:
reply.Message("Enter your one-time password")
}
return nil
}).NamedNext(StateAuthenticated, func(code string, reply Reply, session Session) error {
switch it.Mode {
Expand Down

0 comments on commit 8ba0b8c

Please sign in to comment.