Return attribute dict directly without temporary variable (#41206)
This commit is contained in:
parent
cf5c99d2a9
commit
038c05d0ee
23 changed files with 27 additions and 60 deletions
|
@ -104,9 +104,7 @@ class ImageProcessingAlprEntity(ImageProcessingEntity):
|
|||
@property
|
||||
def state_attributes(self):
|
||||
"""Return device specific state attributes."""
|
||||
attr = {ATTR_PLATES: self.plates, ATTR_VEHICLES: self.vehicles}
|
||||
|
||||
return attr
|
||||
return {ATTR_PLATES: self.plates, ATTR_VEHICLES: self.vehicles}
|
||||
|
||||
def process_plates(self, plates, vehicles):
|
||||
"""Send event with new plates and store data."""
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue