aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--cmd/admin.go4
1 files changed, 4 insertions, 0 deletions
diff --git a/cmd/admin.go b/cmd/admin.go
index 8f8c68f981..eafed24bdd 100644
--- a/cmd/admin.go
+++ b/cmd/admin.go
@@ -578,12 +578,16 @@ func runCreateUser(c *cli.Context) error {
restricted = util.OptionalBoolOf(c.Bool("restricted"))
}
+ // default user visibility in app.ini
+ visibility := setting.Service.DefaultUserVisibilityMode
+
u := &user_model.User{
Name: username,
Email: c.String("email"),
Passwd: password,
IsAdmin: c.Bool("admin"),
MustChangePassword: changePassword,
+ Visibility: visibility,
}
overwriteDefault := &user_model.CreateUserOverwriteOptions{