Skip to content

Commit 78b77a2

Browse files
committed
Migration should fail gracefully even on wrong RT
1 parent 97c7114 commit 78b77a2

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

msal/application.py

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -284,7 +284,7 @@ def get_authorization_request_url(
284284
Can be one of "consumers" or "organizations" or your tenant domain "contoso.com".
285285
If included, it will skip the email-based discovery process that user goes
286286
through on the sign-in page, leading to a slightly more streamlined user experience.
287-
More information on possible values
287+
More information on possible values
288288
`here <https://docs.microsoft.com/en-us/azure/active-directory/develop/v2-oauth2-auth-code-flow#request-an-authorization-code>`_ and
289289
`here <https://docs.microsoft.com/en-us/openspecs/windows_protocols/ms-oapx/86fb452d-e34a-494e-ac61-e526e263b6d8>`_.
290290
:return: The authorization url as a string.
@@ -726,9 +726,10 @@ def acquire_token_by_refresh_token(self, refresh_token, scopes):
726726
"""
727727
return self.client.obtain_token_by_refresh_token(
728728
refresh_token,
729-
decorate_scope(scopes, self.client_id),
729+
scope=decorate_scope(scopes, self.client_id),
730730
rt_getter=lambda rt: rt,
731731
on_updating_rt=False,
732+
on_removing_rt=lambda rt_item: None, # No OP
732733
)
733734

734735

0 commit comments

Comments
 (0)