Commit 795584e
authored
Fix 16840: Navigate to special URLs without throwing errors (#26769)
### Summary
Allow the [manual] navigation to special URL like `https://localhost:5001?keyword=你好 世界`
### Details
`Uri.IsWellFormedUriString` does not tell you whether the URL is valid or not instead it tells if the URL needs to be escaped to further work with it [At least that's how it is currently described and implemented]. To know if a URL is valid `Uri.TryCreate` will do correct job, for additional information please check [Runtime#37634](dotnet/runtime#37634)
ℹ For consideration, other [places in the repo](https://github.com/dotnet/aspnetcore/search?q=Uri.IsWellFormedUriString) might have the same problem.
Addresses #168401 parent be472db commit 795584e
File tree
2 files changed
+16
-5
lines changed- src/Components
- Server/src
- test/E2ETest/Tests
2 files changed
+16
-5
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
89 | 89 | | |
90 | 90 | | |
91 | 91 | | |
92 | | - | |
93 | | - | |
| 92 | + | |
| 93 | + | |
94 | 94 | | |
95 | 95 | | |
96 | 96 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
12 | 12 | | |
13 | 13 | | |
14 | 14 | | |
15 | | - | |
16 | 15 | | |
17 | 16 | | |
18 | 17 | | |
| |||
608 | 607 | | |
609 | 608 | | |
610 | 609 | | |
| 610 | + | |
| 611 | + | |
| 612 | + | |
| 613 | + | |
| 614 | + | |
| 615 | + | |
| 616 | + | |
| 617 | + | |
| 618 | + | |
| 619 | + | |
| 620 | + | |
| 621 | + | |
611 | 622 | | |
612 | 623 | | |
613 | 624 | | |
614 | 625 | | |
615 | 626 | | |
616 | 627 | | |
617 | | - | |
| 628 | + | |
618 | 629 | | |
619 | 630 | | |
620 | 631 | | |
621 | 632 | | |
622 | | - | |
| 633 | + | |
623 | 634 | | |
624 | 635 | | |
625 | 636 | | |
| |||
0 commit comments