FEM: Make temp directory default for solver

Previously it would return None if no setting is found (which can
happen if the settings system hasn't been loaded at least once). This
would make some other code fail.
This commit is contained in:
Markus Hovorka
2019-09-23 21:16:39 +02:00
committed by Bernd Hahnebach
parent 6369b408c2
commit b4128f8614

View File

@@ -158,12 +158,11 @@ def get_custom_dir():
def get_dir_setting():
param_group = FreeCAD.ParamGet(_GENERAL_PARAM)
if param_group.GetBool("UseTempDirectory"):
return TEMPORARY
elif param_group.GetBool("UseBesideDirectory"):
if param_group.GetBool("UseBesideDirectory"):
return BESIDE
elif param_group.GetBool("UseCustomDirectory"):
return CUSTOM
return TEMPORARY
## @}