Loki: Fix issue with recent change to flush code (#5932)
Loki: Fix issue with recent change to flush code (#5932)

* fix flush chunks to pass a reference so we can mutate the chunk contents

Signed-off-by: Edward Welch <4e1cbdeb5d169ce17df53d96f1e78e8fa81360a1@grafana.com>

* update the rest of the helper methods to take a reference of the chunk

Signed-off-by: Edward Welch <4e1cbdeb5d169ce17df53d96f1e78e8fa81360a1@grafana.com>
grafana/loki,grafana/loki,grafana/loki,grafana/loki,grafana/loki,grafana/loki