Reduce logic
@@ -143,8 +143,9 @@ class ImagePathSensors(Entity):
if self.hass.config.external_url is None:
_LOGGER.warn("External URL not set in configuration.")
return f"{self.hass.config.internal_url}/local/mail_and_packages/{self._image}"
- else:
- return f"{self.hass.config.external_url}/local/mail_and_packages/{self._image}"
+ return (
+ f"{self.hass.config.external_url}/local/mail_and_packages/{self._image}"
+ )
else:
return None
