Commit b35fa56
fix(rpc): move CORS layer above AcceptHeaderLayer (#1707)
* fix(rpc): move CORS layer above AcceptHeaderLayer
When AcceptHeaderLayer rejects a request due to an unsupported SDK
version, it short-circuits the response via futures::future::ready()
which bypasses all downstream middleware. Since the CORS layer was
below AcceptHeaderLayer, rejection responses had no CORS headers,
causing browsers to block the error entirely.
* chore: add changelog entry for CORS layer fix
* chore: move changelog entry to v0.13.6 (TBD)
* Update crates/rpc/src/server/mod.rs
Co-authored-by: Mirko <48352201+Mirko-von-Leipzig@users.noreply.github.com>
* Update CHANGELOG.md
Co-authored-by: Mirko <48352201+Mirko-von-Leipzig@users.noreply.github.com>
---------
Co-authored-by: Mirko <48352201+Mirko-von-Leipzig@users.noreply.github.com>1 parent 3b10866 commit b35fa56
2 files changed
Lines changed: 8 additions & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | 2 | | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
3 | 7 | | |
4 | 8 | | |
5 | 9 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
84 | 84 | | |
85 | 85 | | |
86 | 86 | | |
| 87 | + | |
| 88 | + | |
| 89 | + | |
| 90 | + | |
87 | 91 | | |
88 | 92 | | |
89 | 93 | | |
90 | 94 | | |
91 | 95 | | |
92 | | - | |
93 | 96 | | |
94 | 97 | | |
95 | 98 | | |
| |||
0 commit comments