Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gitlab-ce
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kazuhiko Shiozaki
gitlab-ce
Commits
8173ef97
Commit
8173ef97
authored
Mar 25, 2015
by
Stan Hu
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Set Application controller default URL options to ensure all url_for calls are consistent
Closes #1249
parent
6199da0c
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
13 additions
and
0 deletions
+13
-0
CHANGELOG
CHANGELOG
+1
-0
app/controllers/application_controller.rb
app/controllers/application_controller.rb
+12
-0
No files found.
CHANGELOG
View file @
8173ef97
Please view this file on the master branch, on stable branches it's out of date.
v 7.10.0 (unreleased)
- Set Application controller default URL options to ensure all url_for calls are consistent (Stan Hu)
- Allow HTML tags in Markdown input
- Include missing events and fix save functionality in admin service template settings form (Stan Hu)
- Fix "Import projects from" button to show the correct instructions (Stan Hu)
...
...
app/controllers/application_controller.rb
View file @
8173ef97
...
...
@@ -178,6 +178,18 @@ class ApplicationController < ActionController::Base
response
.
headers
[
"Expires"
]
=
"Fri, 01 Jan 1990 00:00:00 GMT"
end
def
default_url_options
if
!
Rails
.
env
.
test?
port
=
Gitlab
.
config
.
gitlab
.
port
unless
Gitlab
.
config
.
gitlab_on_standard_port?
{
host:
Gitlab
.
config
.
gitlab
.
host
,
protocol:
Gitlab
.
config
.
gitlab
.
protocol
,
port:
port
,
script_name:
Gitlab
.
config
.
gitlab
.
relative_url_root
}
else
super
end
end
def
default_headers
headers
[
'X-Frame-Options'
]
=
'DENY'
headers
[
'X-XSS-Protection'
]
=
'1; mode=block'
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment