mirror of
https://github.com/codeninjasllc/discourse.git
synced 2024-11-24 16:18:42 -05:00
18 lines
258 B
Ruby
18 lines
258 B
Ruby
|
require_dependency 'enum_site_setting'
|
||
|
|
||
|
class SlugSetting < EnumSiteSetting
|
||
|
|
||
|
VALUES = %w(ascii encoded none)
|
||
|
|
||
|
def self.valid_value?(val)
|
||
|
VALUES.include?(val)
|
||
|
end
|
||
|
|
||
|
def self.values
|
||
|
VALUES.map do |l|
|
||
|
{name: l, value: l}
|
||
|
end
|
||
|
end
|
||
|
|
||
|
end
|