Create save dir if not exist
This commit is contained in:
parent
03bd2e9b01
commit
c6f87f1c01
@ -104,6 +104,10 @@ def save_configuration(
|
|||||||
if file_path == None or file_path == '':
|
if file_path == None or file_path == '':
|
||||||
return original_file_path # In case a file_path was provided and the user decide to cancel the open action
|
return original_file_path # In case a file_path was provided and the user decide to cancel the open action
|
||||||
|
|
||||||
|
directory = os.path.dirname(file_path)
|
||||||
|
if not os.path.exists(directory):
|
||||||
|
os.makedirs(directory)
|
||||||
|
|
||||||
# Return the values of the variables as a dictionary
|
# Return the values of the variables as a dictionary
|
||||||
variables = {
|
variables = {
|
||||||
name: value
|
name: value
|
||||||
|
Loading…
Reference in New Issue
Block a user