From 5010a118a177d5301c961ebf71d3e5222a9e609d Mon Sep 17 00:00:00 2001 From: Kay Robbins <1189050+VisLab@users.noreply.github.com> Date: Mon, 26 Feb 2024 13:22:28 -0600 Subject: [PATCH] Updated for mixed case extensions --- hed/tools/visualization/tag_word_cloud.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/hed/tools/visualization/tag_word_cloud.py b/hed/tools/visualization/tag_word_cloud.py index c934c389..083e1b7a 100644 --- a/hed/tools/visualization/tag_word_cloud.py +++ b/hed/tools/visualization/tag_word_cloud.py @@ -46,7 +46,7 @@ def create_wordcloud(word_dict, mask_path=None, background_color=None, width=400 kwargs.setdefault('min_font_size', 8) if 'font_path' not in kwargs: kwargs['font_path'] = None - elif kwargs['font_path'] and not kwargs['font_path'].endswith((".ttf", ".otf", ".TTF", ".OTF")): + elif kwargs['font_path'] and not kwargs['font_path'].lower().endswith((".ttf", ".otf")): raise HedFileError("InvalidFontPath", f"Font {kwargs['font_path']} not valid on this system", "") wc = WordCloud(background_color=background_color, mask=mask_image,