--
This commit is contained in:
@@ -128,7 +128,7 @@ async def thumbnail(request: Request, path: str) -> Response:
|
|||||||
svg_filename = "error.svg" if template_type == "error" else "normal.svg"
|
svg_filename = "error.svg" if template_type == "error" else "normal.svg"
|
||||||
fonts_dir = Path.cwd().joinpath("public", "assets", "fonts")
|
fonts_dir = Path.cwd().joinpath("public", "assets", "fonts")
|
||||||
|
|
||||||
svg_path = Path.cwd().joinpath("public", "assets", "images", "thumbnail", svg_filename)
|
svg_path = Path.cwd().joinpath("public", "assets", "images", "thumbnails", svg_filename)
|
||||||
svg = svg_path.read_text(encoding="utf-8")
|
svg = svg_path.read_text(encoding="utf-8")
|
||||||
svg = svg.replace("__PATH__", escape(path_display))
|
svg = svg.replace("__PATH__", escape(path_display))
|
||||||
svg = svg.replace("__TITLE__", escape(title))
|
svg = svg.replace("__TITLE__", escape(title))
|
||||||
|
|||||||
Reference in New Issue
Block a user