Mercurial > gemma
changeset 5253:878d52d95e37 new-fwa
Early calcultion stop to prevent classification in the future.
author | Sascha L. Teichmann <sascha.teichmann@intevation.de> |
---|---|
date | Wed, 13 May 2020 10:26:13 +0200 |
parents | aebe1a12e8b9 |
children | 09ec6a748fca |
files | pkg/controllers/fwa.go |
diffstat | 1 files changed, 4 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/pkg/controllers/fwa.go Wed May 13 09:29:55 2020 +0200 +++ b/pkg/controllers/fwa.go Wed May 13 10:26:13 2020 +0200 @@ -340,8 +340,11 @@ return out.Write(record) } + // Stop yesterday + end := common.MinTime(dusk(time.Now()).Add(-time.Nanosecond), to) + // We step through the time in steps of one day. - for current = from; current.Before(to); { + for current = from; current.Before(end); { next = current.AddDate(0, 0, 1)