Store base URI in Discourse.BaseUri and use it in all places where rootURL was previously used

This commit is contained in:
Wojciech Kocjan
2013-04-04 00:26:47 +02:00
parent bb18b6cb9b
commit a875b1c44a
5 changed files with 9 additions and 25 deletions

View File

@ -18,11 +18,11 @@ module Discourse
RailsMultisite::ConnectionManagement.current_hostname
end
def self.base_uri
def self.base_uri default_value=""
if !ActionController::Base.config.relative_url_root.blank?
return ActionController::Base.config.relative_url_root
else
return ""
return default_value
end
end