Skip to content

Commit

Permalink
SILENT: refactor userPrefsPathName because of a typo
Browse files Browse the repository at this point in the history
  • Loading branch information
xquiet committed Sep 10, 2024
1 parent 59eb9e4 commit 04fe889
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions dnfdragora/config.py
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ def __init__(self, appName) :
self._fileName = appName + ".yaml"
self.systemDir = "/etc/" + appName
pathdir = os.path.expanduser("~") + "/.config/"
self._userPrfesPathName = os.path.join(pathdir, self._fileName)
self._userPrefsPathName = os.path.join(pathdir, self._fileName)

def _load(self) :
'''
Expand All @@ -61,8 +61,8 @@ def _load(self) :
pass

try:
print ("Finally read user settings from %s"%self._userPrfesPathName)
with open(self._userPrfesPathName, 'r') as ymlfile:
print ("Finally read user settings from %s"%self._userPrefsPathName)
with open(self._userPrefsPathName, 'r') as ymlfile:
self._userPrefs = yaml.safe_load(ymlfile)
if not self._userPrefs:
self._userPrefs = {}
Expand Down Expand Up @@ -90,6 +90,6 @@ def saveUserPreferences(self) :
'''
write user preferences into the related configuration file
'''
with open(self._userPrfesPathName, 'w') as outfile:
with open(self._userPrefsPathName, 'w') as outfile:
yaml.dump(self._userPrefs, outfile, default_flow_style=False)

0 comments on commit 04fe889

Please sign in to comment.