cec: Simplify a few code snippets.
[libsigrokdecode.git] / decoders / cec / protocoldata.py
index dd867e0b29503620cb284c2aaa053c8986f112ef..fb8049480a4151cd23d76abf4c2e968266b8623e 100644 (file)
@@ -107,10 +107,7 @@ def resolve_logical_address(id, is_initiator):
 
     # Special handling of 0x0F.
     if id == 0x0F:
-        if is_initiator:
-            return 'Unregistered'
-        else:
-            return 'Broadcast'
+        return 'Unregistered' if is_initiator else 'Broadcast'
 
     return logical_adresses[id]