From 260a285436ed946144dd32c814568c3be49628d8 Mon Sep 17 00:00:00 2001 From: Rambaud Pierrick <12rambau@users.noreply.github.com> Date: Wed, 18 Jan 2023 06:11:06 +0100 Subject: [PATCH] authorize any parameter in the favicon dict (#24) * get is already defaulting to None * accept any type of parameters * add " " around parameter string Co-authored-by: Timo Cornelius Metzger <39711796+tcmetzger@users.noreply.github.com> --- sphinx_favicon/__init__.py | 48 +++++++++++++++++++++----------------- 1 file changed, 26 insertions(+), 22 deletions(-) diff --git a/sphinx_favicon/__init__.py b/sphinx_favicon/__init__.py index c8dd7d1..95b7952 100644 --- a/sphinx_favicon/__init__.py +++ b/sphinx_favicon/__init__.py @@ -49,29 +49,33 @@ def generate_meta(favicon: Dict[str, str]) -> str: favicon: Favicon data Returns: - Favicon meta tag + Favicon link or meta tag """ - rel = favicon.get("rel", "icon") - href = favicon["href"] - meta = f' " + print(html_element) + return html_element def _static_to_href(pathto: Callable, favicon: Dict[str, str]) -> Dict[str, str]: