From d10a462fedbd7794a83abdba9b4526600f71de5b Mon Sep 17 00:00:00 2001 From: GitLab Bot Date: Mon, 16 Dec 2019 12:07:43 +0000 Subject: Add latest changes from gitlab-org/gitlab@master --- app/models/application_setting.rb | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'app/models/application_setting.rb') diff --git a/app/models/application_setting.rb b/app/models/application_setting.rb index e764b6c56b0..456b6430088 100644 --- a/app/models/application_setting.rb +++ b/app/models/application_setting.rb @@ -46,6 +46,12 @@ class ApplicationSetting < ApplicationRecord presence: true, numericality: { only_integer: true, greater_than_or_equal_to: 0 } + validates :minimum_password_length, + presence: true, + numericality: { only_integer: true, + greater_than_or_equal_to: DEFAULT_MINIMUM_PASSWORD_LENGTH, + less_than_or_equal_to: Devise.password_length.max } + validates :home_page_url, allow_blank: true, addressable_url: true, -- cgit v1.2.3