From d61f30b62c605e35e8b46e08f1ace6c16e708466 Mon Sep 17 00:00:00 2001 From: B_Ries Date: Thu, 22 Apr 2021 11:45:06 +0200 Subject: [PATCH] Update imd_blocks.py just a minor save --- pygromos/files/blocks/imd_blocks.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/pygromos/files/blocks/imd_blocks.py b/pygromos/files/blocks/imd_blocks.py index 4ea5691f..95d24855 100644 --- a/pygromos/files/blocks/imd_blocks.py +++ b/pygromos/files/blocks/imd_blocks.py @@ -607,6 +607,9 @@ def block_to_string(self) -> str: result += " " + str(self.ALGORITHM) + "\n" if(self.ALGORITHM == "2"): + if(self.NUM is None): + raise Exception("You need to specify the NUM parameter for MULTIBATH if ALGORITHM is 2!") + result += "# " + "\t".join(self._order[0][1]) + "\n" result += " " + str(self.NUM) + "\n"