Skip to content

Commit d81cee0

Browse files
committed
Tweak
1 parent 00840fd commit d81cee0

1 file changed

Lines changed: 3 additions & 2 deletions

File tree

pelicanconf.py

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@
33
from pathlib import Path
44

55
from jinja2 import Environment, FileSystemLoader
6+
from markupsafe import Markup
67
from markdown import Markdown
78
from markdown.extensions import Extension
89
from markdown.extensions.admonition import AdmonitionExtension
@@ -25,8 +26,8 @@ def sponsor_img(name: str):
2526

2627

2728
class SponsorInlineProcessor(InlineProcessor):
28-
def handleMatch(self, m: re.Match[str], data: str) -> tuple[str, int, int]:
29-
return sponsor_template.render(SPONSORS=SPONSORS), m.start(0), m.end(0)
29+
def handleMatch(self, m: re.Match[str], data: str) -> tuple[Markup, int, int]:
30+
return Markup(sponsor_template.render(SPONSORS=SPONSORS), m.start(0), m.end(0))
3031

3132

3233
class SponsorExtension(Extension):

0 commit comments

Comments
 (0)