Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/lib/api
diff options
context:
space:
mode:
authorRobert Speicher <robert@gitlab.com>2017-07-28 21:05:58 +0300
committerRobert Speicher <robert@gitlab.com>2017-07-28 21:05:58 +0300
commitda967803cce971b184873dbe5d65d07215de0b0a (patch)
tree46f7eb329794afb3d5139b776ae8a6fcfe1372ab /lib/api
parent62e9bb16dcac64549b622ad44d984035e643c680 (diff)
parenta2ba403e27183073ad9a4894cfe6c39f94e63964 (diff)
Merge branch '35599-fix-uncontrolled-default_url_options-overriding' into 'master'
Ensure Gitlab.config.gitlab.host/port and Gitlab::Application.routes.default_url_options are set correctly in Capybara + :js specs Closes #35599 See merge request !13126
Diffstat (limited to 'lib/api')
-rw-r--r--lib/api/helpers/related_resources_helpers.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/api/helpers/related_resources_helpers.rb b/lib/api/helpers/related_resources_helpers.rb
index 769cc1457fc..1f677529b07 100644
--- a/lib/api/helpers/related_resources_helpers.rb
+++ b/lib/api/helpers/related_resources_helpers.rb
@@ -12,7 +12,7 @@ module API
end
def expose_url(path)
- url_options = Rails.application.routes.default_url_options
+ url_options = Gitlab::Application.routes.default_url_options
protocol, host, port = url_options.slice(:protocol, :host, :port).values
URI::HTTP.build(scheme: protocol, host: host, port: port, path: path).to_s