Use assignment expressions 11 (#57792)

This commit is contained in:
Marc Mueller 2021-10-17 20:15:48 +02:00 committed by GitHub
parent 238b488642
commit aa7dc78a1e
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
25 changed files with 45 additions and 111 deletions

View file

@ -420,9 +420,7 @@ def handle_entity_source(
perm_category=CAT_ENTITIES,
)
source = raw_sources.get(entity_id)
if source is None:
if (source := raw_sources.get(entity_id)) is None:
connection.send_error(msg["id"], ERR_NOT_FOUND, "Entity not found")
return