Skip to content

Commit 7e258c7

Browse files
committed
review change
1 parent 53167d2 commit 7e258c7

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

msal/application.py

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -845,8 +845,7 @@ def acquire_token_interactive(self,
845845
domain_hint=None, # type: Optional[str]
846846
claims_challenge=None,
847847
):
848-
if not port:
849-
port = _get_open_port()
848+
_port = port or _get_open_port()
850849
redirect_uri = "http://localhost:%d" % port
851850
request_state = str(uuid.uuid4())
852851
auth_url = self.get_authorization_request_url(
@@ -858,7 +857,7 @@ def acquire_token_interactive(self,
858857
prompt=prompt,
859858
domain_hint=domain_hint,
860859
claims_challenge=claims_challenge,)
861-
auth_code, state = obtain_auth_code(port, auth_uri=auth_url)
860+
auth_code, state = obtain_auth_code(_port, auth_uri=auth_url)
862861
if not auth_code:
863862
raise TimeoutError("Server timed out")
864863
if request_state != state:

0 commit comments

Comments
 (0)