From aa505aa6e14b8f76deadf43a52c818d0cb111ec8 Mon Sep 17 00:00:00 2001 From: weckyy702 Date: Sun, 27 Dec 2020 17:33:50 +0100 Subject: [PATCH] fixed bug where no font path would result in error --- gui/utils.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gui/utils.py b/gui/utils.py index a205259..056be0e 100644 --- a/gui/utils.py +++ b/gui/utils.py @@ -6,7 +6,7 @@ from draw.Iinstruction import * def nassi(filepath:str, output_path: str, gui, font_filepath: str=None): NSD = NassiShneidermanDiagram(gui.debug_mode) - if font_filepath: + if font_filepath is not None and font_filepath is not "": NSD.set_font(font_filepath) NSD.load_from_file(filepath) NSD.convert_to_image(output_path, 500)