From 95b0c952e0d91054fec39fcc3b93b83783b8e669 Mon Sep 17 00:00:00 2001 From: Kriti Godey Date: Thu, 20 Jan 2022 17:28:39 -0500 Subject: [PATCH] Fixed issue with incorrectly identifying unused images --- scripts/util/links.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/scripts/util/links.py b/scripts/util/links.py index a4f0151d4..ca40dd4ba 100644 --- a/scripts/util/links.py +++ b/scripts/util/links.py @@ -68,8 +68,8 @@ def resolve_wiki_link(link, file): """ Converts wiki.js link to usable local path """ - # Remove styling that might be part of image links - link = link.split(" ")[0] + # Remove styling that might be part of image links (e.g. "x.png =240x") + link = link.split(" =")[0] # Remove fragments if they exist link = link.split("#")[0] # Add .md extension is there is no extension