diff --git a/pyhydroquebec/__main__.py b/pyhydroquebec/__main__.py index f1b1bc7..3c7e2de 100644 --- a/pyhydroquebec/__main__.py +++ b/pyhydroquebec/__main__.py @@ -161,7 +161,7 @@ def main(): elif args.dump_data: pprint(results[0].__dict__) elif args.influxdb: - output_influx(results[0]) + output_influx(results[0], args.hourly) elif args.json or args.detailled_energy: output_json(results[0], args.hourly) else: diff --git a/pyhydroquebec/outputter.py b/pyhydroquebec/outputter.py index f2a1eb9..7741d1f 100644 --- a/pyhydroquebec/outputter.py +++ b/pyhydroquebec/outputter.py @@ -36,7 +36,7 @@ def output_influx(customer, show_hourly=False): #"batch_size" : 100, } db = InfluxDB(_params) - db.write_data_to_db(customer) + db.write_data_to_db(customer, show_hourly=show_hourly) print("Sent this to InfluxDB") output_text(customer, show_hourly=show_hourly)