From: Uwe Hermann Date: Sat, 24 Sep 2016 11:20:16 +0000 (+0200) Subject: usb_request: Use "is" or "is not" with None. X-Git-Tag: libsigrokdecode-0.5.0~143 X-Git-Url: https://sigrok.org/gitaction?a=commitdiff_plain;h=8657abb6e0aecf0e7e76f6f757292ec5bd6e8205;p=libsigrokdecode.git usb_request: Use "is" or "is not" with None. --- diff --git a/decoders/usb_request/pd.py b/decoders/usb_request/pd.py index 39a9df6..bb7aedc 100644 --- a/decoders/usb_request/pd.py +++ b/decoders/usb_request/pd.py @@ -201,7 +201,7 @@ class Decoder(srd.Decoder): self.handle_request(request_started, request_end) # CONTROL, SETUP stage - elif request['type'] == None and self.transaction_type == 'SETUP': + elif request['type'] is None and self.transaction_type == 'SETUP': request['setup_data'] = self.transaction_data request['wLength'] = struct.unpack('