mirror of
https://github.com/filebrowser/filebrowser.git
synced 2025-07-16 13:00:27 +00:00
fix: print correct user on setup
This commit is contained in:
parent
545c972214
commit
88f1442932
@ -364,6 +364,8 @@ func setupLog(logMethod string) {
|
||||
}
|
||||
|
||||
func quickSetup(flags *pflag.FlagSet, d pythonData) {
|
||||
log.Println("Performing quick setup")
|
||||
|
||||
set := &settings.Settings{
|
||||
Key: generateKey(),
|
||||
Signup: false,
|
||||
@ -430,10 +432,11 @@ func quickSetup(flags *pflag.FlagSet, d pythonData) {
|
||||
pwd, err = users.RandomPwd(set.MinimumPasswordLength)
|
||||
checkErr(err)
|
||||
|
||||
log.Println("Randomly generated password for user 'admin':", pwd)
|
||||
|
||||
log.Printf("User '%s' initialized with randomly generated password: %s\n", username, pwd)
|
||||
password, err = users.ValidateAndHashPwd(pwd, set.MinimumPasswordLength)
|
||||
checkErr(err)
|
||||
} else {
|
||||
log.Printf("User '%s' initialize wth user-provided password\n", username)
|
||||
}
|
||||
|
||||
if username == "" || password == "" {
|
||||
|
Loading…
x
Reference in New Issue
Block a user