fd
This commit is contained in:
parent
f74bb1808e
commit
3864bba3a6
14 changed files with 39 additions and 43 deletions
|
@ -92,9 +92,9 @@ class CustomRenderer(HTMLRenderer):
|
|||
def render_sub_mention(self, token):
|
||||
space = token.target[0]
|
||||
target = token.target[1]
|
||||
return f'{space}<a href="https://old.reddit.com/r/{target}" class="d-inline-block">r/{target}</a>'
|
||||
return f'{space}<a href="https://old.reddit.com/r/{target}" rel="nofollow noopener noreferrer" class="d-inline-block">r/{target}</a>'
|
||||
|
||||
def render_redditor_mention(self, token):
|
||||
space = token.target[0]
|
||||
target = token.target[1]
|
||||
return f'{space}<a href="https://old.reddit.com/u/{target}" class="d-inline-block">u/{target}</a>'
|
||||
return f'{space}<a href="https://old.reddit.com/u/{target}" rel="nofollow noopener noreferrer" class="d-inline-block">u/{target}</a>'
|
Loading…
Add table
Add a link
Reference in a new issue