diff --git a/app/models/global_setting.rb b/app/models/global_setting.rb index 01ee1ff1ecf..c9de7b2b280 100644 --- a/app/models/global_setting.rb +++ b/app/models/global_setting.rb @@ -66,7 +66,8 @@ class GlobalSetting class EnvProvider < BaseProvider def lookup(key, default) - resolve(ENV["DISCOURSE_" << key.to_s.upcase], default) + var = ENV["DISCOURSE_" << key.to_s.upcase] + resolve(var , var.nil? ? default : nil) end end