Skip to content

Commit 5eb12e9

Browse files
committed
Fix a/an use
1 parent f752180 commit 5eb12e9

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

docs/upgrading-to-6-0.md

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ end
1818
SecureHeaders.use_secure_headers_override(request, :dynamic_override)
1919
```
2020

21-
Prior to 6.0.0, the response would NOT include an `X-Frame-Options` header since the named override would be a copy of the default configuration, but with `X-Content-Type-Options` set to `nosniff`. As of 6.0.0, the above code results in both `X-Frame-Options` set to `DENY` AND `X-Content-Type-Options` to `nosniff`.
21+
Prior to 6.0.0, the response would NOT include a `X-Frame-Options` header since the named override would be a copy of the default configuration, but with `X-Content-Type-Options` set to `nosniff`. As of 6.0.0, the above code results in both `X-Frame-Options` set to `DENY` AND `X-Content-Type-Options` to `nosniff`.
2222

2323
## `ContentSecurityPolicyConfig#merge` and `ContentSecurityPolicyReportOnlyConfig#merge` work more like `Hash#merge`
2424

@@ -30,4 +30,8 @@ This method is not typically directly called by users of SecureHeaders. Given th
3030

3131
## Configuration headers are no longer cached
3232

33-
Prior to 6.0.0 SecureHeaders prebuilt and cached the headers that corresponded to the default configuration. The same was also done for named overrides. However, now that named overrides are applied dynamically, those can no longer be cached. As a result, caching has been removed in the name of simplicity. Some micro-benchmarks indicate this shouldn't be a performmance problem and will help to elimiate a class of bugs entirely.
33+
Prior to 6.0.0 SecureHeaders pre-built and cached the headers that corresponded to the default configuration. The same was also done for named overrides. However, now that named overrides are applied dynamically, those can no longer be cached. As a result, caching has been removed in the name of simplicity. Some micro-benchmarks indicate this shouldn't be a performance problem and will help to eliminate a class of bugs entirely.
34+
35+
## Configuration the default configuration more than once will result in an Exception
36+
37+
Prior to 6.0.0 you could conceivably, though unlikely, have `Configure#default` called more than once. Because configurations are dynamic, configuring more than once could result in unexpected behavior. So, as of 6.0.0 we raise a `AlreadyConfiguredError` if the default configuration is setup more than once.

0 commit comments

Comments
 (0)