Skip to content

Commit

Permalink
Fix AttributeError in CI
Browse files Browse the repository at this point in the history
- Use WINEPREFIX from the environment then use Proton's environment. The value of WINEPREFIX set from a umu client and WINEPREFIX from the proton script are basically equivalent as they refer to the same filesystem paths, so there should be no functional differences.
  • Loading branch information
R1kaB3rN committed Jul 14, 2024
1 parent 4aaff22 commit 36c8d90
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion fix.py
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ def get_game_id() -> str:
def get_game_name() -> str: #pylint: disable=R0914
""" Trys to return the game name from environment variables
"""
pfx = protonmain.g_session.env.get('WINEPREFIX')
pfx = os.environ.get('WINEPREFIX') or protonmain.g_session.env.get('WINEPREFIX')

if os.environ.get('UMU_ID'):
if os.path.isfile(f'{pfx}/game_title'):
Expand Down

0 comments on commit 36c8d90

Please sign in to comment.