mirror of
https://github.com/discourse/discourse.git
synced 2025-06-04 23:36:11 +08:00
DEV: Add file_size_restriction site setting type (#24704)
This change will allow admins to configure file sizes in mb instead of having to convert to kb. Co-authored-by: Ella <ella.estigoy@gmail.com>
This commit is contained in:
@ -34,6 +34,8 @@ class Admin::SiteSettingsController < Admin::AdminController
|
||||
case SiteSetting.type_supervisor.get_type(id)
|
||||
when :integer
|
||||
value = value.tr("^-0-9", "")
|
||||
when :file_size_restriction
|
||||
value = value.tr("^-0-9", "")
|
||||
when :uploaded_image_list
|
||||
value = Upload.get_from_urls(value.split("|")).to_a
|
||||
end
|
||||
|
Reference in New Issue
Block a user