mirror of
https://github.com/xcat2/confluent.git
synced 2026-09-30 14:55:18 +00:00
Allow cachied sensor readings up to a second old.
In the process of reworking cache logic, a temporary disabling was left in. Before the logic change, 'cache' of '1' meant 'True', but the intent was a max age to decline to reply. This allows very close together requests to be cached.
This commit is contained in:
@@ -1967,7 +1967,7 @@ class OEMHandler(object):
|
||||
if 'sensedata' in sensor:
|
||||
reading = sensor['sensedata']
|
||||
else:
|
||||
reading = await self._do_web_request(sensor['url'], cache=False)
|
||||
reading = await self._do_web_request(sensor['url'], cache=1)
|
||||
return self._extract_reading(sensor, reading)
|
||||
|
||||
async def get_sensor_data(self):
|
||||
|
||||
Reference in New Issue
Block a user