Skip to content

Commit

Permalink
Fix load issue in safari (#487)
Browse files Browse the repository at this point in the history
  • Loading branch information
ludeeus authored Jun 20, 2021
1 parent 3ff4e4d commit 5efd0e7
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions src/tools/markdown/markdown.ts
Original file line number Diff line number Diff line change
Expand Up @@ -68,11 +68,10 @@ export class markdown {

// Add references to issues and PRs
if (repo) {
input = input.replace(/(?:(?<![/\w-.])\w[\w-.]+\/\w[\w-.]+|\B)#[1-9]\d*\b/g, (reference) => {
input = input.replace(/(?:\w[\w-.]+\/\w[\w-.]+|\B)#[1-9]\d*\b/g, (reference) => {
const fullReference = reference.replace(/^#/, `${repo.full_name}#`);
const [fullName, issue] = fullReference.split("#");
const url = `https://github.com/${fullName}/issues/${issue}`;
return `[${reference}](${url})`;
return `[${reference}](https://github.com/${fullName}/issues/${issue})`;
});
}

Expand Down

0 comments on commit 5efd0e7

Please sign in to comment.