move settings for email domain bug #1018

A recent Rails bump caused prod emails to generate links with a domain of
'example.com'. The other settings in config/initializers/production.rb were
fine, implying config/application.rb was running a second time after
initializers (very unlikely) or something subtle in the class changed to
prevent overriding (also feels unlikely). I'd rather simplify our prod config
than debug further.
This commit is contained in:
Peter Bhat Harkins 2021-12-01 07:55:08 -06:00
parent f70395b9f8
commit 8a4ecb93d6
1 changed files with 7 additions and 4 deletions

View File

@ -67,11 +67,14 @@ silence_warnings do
ActionDispatch::Http::Parameters::DEFAULT_PARSERS = {}.freeze
end
# define site name and domain to be used globally, should be overridden in a
# local file such as config/initializers/production.rb
# site-wide settings
class << Rails.application
def allow_invitation_requests?
true
false
end
def allow_new_users_to_invite?
false
end
def open_signups?
@ -79,7 +82,7 @@ class << Rails.application
end
def domain
"example.com"
"lobste.rs"
end
def name