Refactor unnecessary else / elif when if block has a return statement

This commit is contained in:
deepsource-autofix[bot]
2021-04-09 23:30:53 +00:00
committed by GitHub
parent 86ae06de51
commit bd2a63653b
19 changed files with 52 additions and 70 deletions

View File

@@ -73,8 +73,7 @@ class MercuryClient(PacketsReceiver.PacketsReceiver, Closeable):
resp = self.send_sync(request.request)
if 200 <= resp.status_code < 300:
return json.loads(resp.payload[0])
else:
raise MercuryClient.MercuryException(resp)
raise MercuryClient.MercuryException(resp)
def send(self, request: RawMercuryRequest, callback) -> int:
buffer = BytesOutputStream()