(mode: ContentSecurityPolicyMode)
| 61 | ) { |
| 62 | return configuredMode; |
| 63 | } |
| 64 | return 'report-only'; |
| 65 | } |
| 66 | |
| 67 | export function getContentSecurityPolicyHeaderName(mode: ContentSecurityPolicyMode): string | null { |
| 68 | if (mode === 'off') return null; |
| 69 | if (mode === 'report-only') return 'Content-Security-Policy-Report-Only'; |
| 70 | return 'Content-Security-Policy'; |
no outgoing calls
no test coverage detected