temperature_store: Add configparser support
Signed-off-by: Eric Callahan <arksine.code@gmail.com>
This commit is contained in:
parent
470cc13b0e
commit
0abfc76871
|
@ -11,8 +11,8 @@ TEMPERATURE_UPDATE_MS = 1000
|
|||
TEMPERATURE_STORE_SIZE = 20 * 60
|
||||
|
||||
class TemperatureStore:
|
||||
def __init__(self, server):
|
||||
self.server = server
|
||||
def __init__(self, config):
|
||||
self.server = config.get_server()
|
||||
|
||||
# Temperature Store Tracking
|
||||
self.last_temps = {}
|
||||
|
@ -98,5 +98,5 @@ class TemperatureStore:
|
|||
async def close(self):
|
||||
self.temp_update_cb.stop()
|
||||
|
||||
def load_plugin(server):
|
||||
return TemperatureStore(server)
|
||||
def load_plugin(config):
|
||||
return TemperatureStore(config)
|
||||
|
|
Loading…
Reference in New Issue