Skip to content

Commit d5ed15f

Browse files
author
Jonathan Lutterbeck
committed
Fixed error
Moved the syspath cariable to be globally available
1 parent 3566688 commit d5ed15f

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

examples/configloader.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,6 @@ def create_config(path):
3636
print(f"New config file created, edit config file at: {syspath}")
3737

3838
def load_config(path):
39-
syspath = which_path() + "/config.yaml"
4039

4140
if not os.path.exists(syspath):
4241
create_config(syspath)
@@ -50,3 +49,5 @@ def load_config(path):
5049

5150
except yaml.YAMLError as exc:
5251
print(exc)
52+
53+
syspath = which_path() + "/config.yaml"

0 commit comments

Comments
 (0)