Skip to content

Commit 5a8b881

Browse files
committed
Should have used non-positional syntax
1 parent b4bc23b commit 5a8b881

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

app.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ def authorized():
3232
if request.args['state'] != session.get("state"):
3333
return redirect(url_for("login"))
3434
cache = _load_cache()
35-
result = _build_msal_app(cache).acquire_token_by_authorization_code(
35+
result = _build_msal_app(cache=cache).acquire_token_by_authorization_code(
3636
request.args['code'],
3737
scopes=app_config.SCOPE, # Misspelled scope would cause an HTTP 400 error here
3838
redirect_uri=url_for("authorized", _external=True))
@@ -79,7 +79,7 @@ def _build_msal_app(cache=None):
7979

8080
def _get_token_from_cache(scope=None):
8181
cache = _load_cache() # This web app maintains one cache per session
82-
cca = _build_msal_app(cache)
82+
cca = _build_msal_app(cache=cache)
8383
accounts = cca.get_accounts()
8484
if accounts: # So all account(s) belong to the current signed-in user
8585
result = cca.acquire_token_silent(scope, account=accounts[0])

0 commit comments

Comments
 (0)