File tree 1 file changed +2
-12
lines changed
1 file changed +2
-12
lines changed Original file line number Diff line number Diff line change 4
4
require 'gitlab/current_settings'
5
5
include Gitlab ::CurrentSettings
6
6
7
- # If Sentry is enabled and the Rails app is running in production mode,
8
- # this will construct the Report URI for Sentry.
9
- if Rails . env . production? && current_application_settings . sentry_enabled
10
- uri = URI . parse ( current_application_settings . sentry_dsn )
11
- CSP_REPORT_URI = "#{ uri . scheme } ://#{ uri . host } /api#{ uri . path } /csp-report/?sentry_key=#{ uri . user } "
12
- else
13
- CSP_REPORT_URI = ''
14
- end
7
+ CSP_REPORT_URI = ''
15
8
16
9
# Content Security Policy Headers
17
10
# For more information on CSP see:
71
64
upgrade_insecure_requests : true
72
65
}
73
66
74
- # Reports are sent to Sentry if it's enabled.
75
- if current_application_settings . sentry_enabled
76
- config . csp [ :report_uri ] = %W( #{ CSP_REPORT_URI } )
77
- end
67
+ config . csp [ :report_uri ] = %W( #{ CSP_REPORT_URI } )
78
68
79
69
# Allow Bootstrap Linter in development mode.
80
70
if Rails . env . development?
You can’t perform that action at this time.
0 commit comments