mirror of
https://github.com/discourse/discourse.git
synced 2025-02-25 18:55:32 -06:00
Add validation of string site settings with regex, and min and max lengths
This commit is contained in:
@@ -10,7 +10,7 @@ class IntegerSettingValidator
|
||||
true
|
||||
end
|
||||
|
||||
def error_message(val)
|
||||
def error_message
|
||||
if @opts[:min] && @opts[:max]
|
||||
I18n.t('site_settings.errors.invalid_integer_min_max', {min: @opts[:min], max: @opts[:max]})
|
||||
elsif @opts[:min]
|
||||
|
||||
Reference in New Issue
Block a user