feat: Make USERNAME_MIN_LENGTH customizable
This commit is contained in:
@@ -14,7 +14,7 @@ NAME_MIN_LENGTH = 1
|
||||
NAME_MAX_LENGTH = 255
|
||||
|
||||
# The minimum and maximum length for the username account field
|
||||
USERNAME_MIN_LENGTH = 2
|
||||
USERNAME_MIN_LENGTH = getattr(settings, 'USERNAME_MIN_LENGTH', 2)
|
||||
# Note: 30 chars is the default for historical reasons. Django uses 150 as the username length since 1.10
|
||||
USERNAME_MAX_LENGTH = getattr(settings, 'USERNAME_MAX_LENGTH', 30)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user