From 757758293f34b3bd74167cf03bfb013a9d106790 Mon Sep 17 00:00:00 2001 From: darwincereska Date: Wed, 1 Apr 2026 21:42:00 -0400 Subject: [PATCH] fix --- main.go | 23 ++++++++++++----------- 1 file changed, 12 insertions(+), 11 deletions(-) diff --git a/main.go b/main.go index 1dc4a02..da3cea3 100644 --- a/main.go +++ b/main.go @@ -26,17 +26,18 @@ func main() { os.Exit(1) } - // Fetch user input - fmt.Print("Enter your password: ") - fmt.Scanf("%s", &input) - fmt.Println(input) + for { - // Check users password - message, err := password.Check(input, commonWords, commonPasswords) - if err != nil { - fmt.Printf("ERROR: %v\n", err) - os.Exit(1) + // Fetch user input + fmt.Print("Enter your password: ") + fmt.Scanf("%s", &input) + fmt.Println(input) + + // Check users password + message, err := password.Check(input, commonWords, commonPasswords) + if err != nil { + fmt.Printf("ERROR: %v\n", err) + } + fmt.Println(message) } - fmt.Println(message) - }