Skip to content

Commit

Permalink
Merge pull request #149 from SUSE/new-osc-conf-format
Browse files Browse the repository at this point in the history
Support for new OSC config
  • Loading branch information
der-gabe authored Dec 11, 2023
2 parents f94f372 + 8e2ec87 commit 04d772f
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion osctiny/utils/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -199,7 +199,12 @@ def get_cookie_jar() -> typing.Optional[LWPCookieJar]:
.. versionadded:: 0.8.0
"""
if _conf is not None:
path = _conf._identify_osccookiejar() # pylint: disable=protected-access
try:
# New OSC config
path = _conf.config.cookiejar
except AttributeError:
# Backward compatibility to old OSC config style
path = _conf._identify_osccookiejar() # pylint: disable=protected-access
if os.path.isfile(path):
return LWPCookieJar(filename=path)

Expand Down

0 comments on commit 04d772f

Please sign in to comment.