mirror of
https://github.com/skaringa/water-counter.git
synced 2024-11-23 18:04:25 +01:00
Avoid error when no data is available
This commit is contained in:
parent
dcd1ac89df
commit
05004cbac0
@ -73,6 +73,7 @@ def detect_pauses(data):
|
|||||||
def main():
|
def main():
|
||||||
#counter = read_fetch_output()
|
#counter = read_fetch_output()
|
||||||
counter = read_rrd()
|
counter = read_rrd()
|
||||||
|
if len(counter) > 0:
|
||||||
pauses = detect_pauses(counter)
|
pauses = detect_pauses(counter)
|
||||||
if verbose:
|
if verbose:
|
||||||
for p in pauses:
|
for p in pauses:
|
||||||
|
Loading…
Reference in New Issue
Block a user