mirror of
https://github.com/cisagov/manage.get.gov.git
synced 2025-06-03 11:07:25 +02:00
Fix bad logic
This commit is contained in:
parent
d943b69b3d
commit
2f4425d914
1 changed files with 7 additions and 1 deletions
|
@ -61,7 +61,13 @@ class Socket:
|
|||
return False
|
||||
else:
|
||||
self.disconnect()
|
||||
return not self.is_login_error(response.code)
|
||||
|
||||
# If we encounter a login error, fail
|
||||
if self.is_login_error(response.code):
|
||||
return False
|
||||
|
||||
# otherwise, just return true
|
||||
return True
|
||||
|
||||
def disconnect(self):
|
||||
"""Close the connection."""
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue