All checks were successful
continuous-integration/drone/push Build is passing
Move the various sections to their own concerns, so they're easier to find and maintain
17 lines
448 B
Ruby
17 lines
448 B
Ruby
module Settings
|
|
module MastodonSettings
|
|
extend ActiveSupport::Concern
|
|
|
|
included do
|
|
field :mastodon_public_url, type: :string,
|
|
default: ENV["MASTODON_PUBLIC_URL"].presence
|
|
|
|
field :mastodon_enabled, type: :boolean,
|
|
default: ENV["MASTODON_PUBLIC_URL"].present?
|
|
|
|
field :mastodon_address_domain, type: :string,
|
|
default: ENV["MASTODON_ADDRESS_DOMAIN"].presence || self.primary_domain
|
|
end
|
|
end
|
|
end
|