Skip to content

Commit

Permalink
more accurately detect when not logged in to epic and avoid errors wh…
Browse files Browse the repository at this point in the history
…en credentials expire
  • Loading branch information
alkazar committed Jan 9, 2024
1 parent 467b793 commit c29ca63
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 4 deletions.
5 changes: 2 additions & 3 deletions chimera_app/platforms/epic_store.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,8 @@ def __init__(self):
'metadata')

def is_authenticated(self):
return os.path.isfile(os.path.join(context.CONFIG_HOME,
"legendary",
"user.json"))
output = subprocess.check_output(['legendary', 'status'])
return '<not logged in>' not in output.decode('utf-8')

def authenticate(self, password):
clean_password = password.replace('authorizationCode', '')
Expand Down
2 changes: 1 addition & 1 deletion views/custom_login.tpl
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
% rebase('base.tpl')

% if platform == 'epic-store':
<p class="platform-login-description">Please make sure you are logged in to your Epic Games Store account, then <a target="_blank" href="https://www.epicgames.com/id/api/redirect?clientId=34a02cf8f4414e29b15921876da36f9a&responseType=code">click this link</a> and paste the authorization code that appears into the input box below.</p>
<p class="platform-login-description">Please <a target="_blank" href="https://legendary.gl/epiclogin">click this link</a>, login to your Epic account if not already logged in, and paste the authorization code that appears into the input box below.</p>
% elif platform == 'gog':
<p class="platform-login-description">Please <a target="_blank" href="https://login.gog.com/auth?client_id=46899977096215655&amp;layout=client2%22&amp;redirect_uri=https%3A%2F%2Fembed.gog.com%2Fon_login_success%3Forigin%3Dclient&amp;response_type=code">login to GOG</a>. A blank page will appear with a code in the address bar after "code=". Paste the code from the address bar into the input box below.</p>
% end
Expand Down

0 comments on commit c29ca63

Please sign in to comment.