Remove unnecessary cache (#40)

The cache was useful trick when the property accesses caused I/O,
which is unnecessary now as dev.update() does explicitly cache results until its called again.
This commit is contained in:
Teemu R
2020-04-12 15:57:49 +02:00
committed by GitHub
parent 5ff299664e
commit c90465c5dd
6 changed files with 13 additions and 98 deletions

View File

@@ -35,8 +35,8 @@ class SmartPlug(SmartDevice):
and should be handled by the user of the library.
"""
def __init__(self, host: str, *, cache_ttl: int = 3) -> None:
SmartDevice.__init__(self, host, cache_ttl=cache_ttl)
def __init__(self, host: str) -> None:
super().__init__(host)
self.emeter_type = "emeter"
self._device_type = DeviceType.Plug