Pārlūkot izejas kodu

Fixes #1745: avoids encoding #

main
Eric Amodio pirms 2 gadiem
vecāks
revīzija
83d4d89068
3 mainītis faili ar 3 papildinājumiem un 3 dzēšanām
  1. +1
    -0
      CHANGELOG.md
  2. +1
    -1
      src/git/remotes/provider.ts
  3. +1
    -2
      src/system/encoding.ts

+ 1
- 0
CHANGELOG.md Parādīt failu

@ -23,6 +23,7 @@ The format is based on [Keep a Changelog](http://keepachangelog.com/) and this p
### Fixed
- Fixes [#1745](https://github.com/gitkraken/vscode-gitlens/issues/1745) - autolinks.url encodes hash char
- Fixes [#1572](https://github.com/gitkraken/vscode-gitlens/issues/1572) - Forced regular expression search in changes
- Fixes [#1473](https://github.com/gitkraken/vscode-gitlens/issues/1473) - Support VSCodium in interactive rebase editor
- Fixes performance issue with the rich hover on the status bar blame

+ 1
- 1
src/git/remotes/provider.ts Parādīt failu

@ -234,7 +234,7 @@ export abstract class RemoteProvider implements RemoteProviderReference {
protected encodeUrl(url: string): string;
protected encodeUrl(url: string | undefined): string | undefined;
protected encodeUrl(url: string | undefined): string | undefined {
return Encoding.encodeUrl(url);
return Encoding.encodeUrl(url)?.replace(/#/g, '%23');
}
}

+ 1
- 2
src/system/encoding.ts Parādīt failu

@ -6,6 +6,5 @@ export function encodeUrl(url: string | undefined): string | undefined {
if (url == null) return undefined;
// Not a fan of this, but it's hard to gauge previous encoding and this is the most common case
url = url.replace(/%20/g, ' ');
return encodeURI(url).replace(/#/g, '%23');
return encodeURI(url.replace(/%20/g, ' '));
}

Notiek ielāde…
Atcelt
Saglabāt