mirror of
https://github.com/Microsoft/vscode
synced 2024-08-28 13:29:44 +00:00
Split href before decoding instead of after
Fixes #123228 This fixes the case where `#` appears in the path
This commit is contained in:
parent
6af49913c2
commit
6ee883bfa3
|
@ -428,7 +428,8 @@ class MarkdownPreview extends Disposable implements WebviewResourceProvider {
|
|||
|
||||
|
||||
private async onDidClickPreviewLink(href: string) {
|
||||
let [hrefPath, fragment] = decodeURIComponent(href).split('#');
|
||||
const [rawPath, fragment] = href.split('#');
|
||||
let hrefPath = decodeURIComponent(rawPath);
|
||||
|
||||
if (hrefPath[0] !== '/') {
|
||||
// We perviously already resolve absolute paths.
|
||||
|
|
Loading…
Reference in a new issue