fix off-by-one error in replication download

This commit is contained in:
Sarah Hoffmann
2021-02-04 17:04:04 +01:00
parent 82ef02cd1a
commit 861e67dfe8
2 changed files with 3 additions and 2 deletions

View File

@@ -336,7 +336,8 @@ class UpdateReplication:
conn = connect(args.config.get_libpq_dsn())
start = dt.datetime.now(dt.timezone.utc)
state = replication.update(conn, params)
status.log_status(conn, start, 'import')
if state is not replication.UpdateState.NO_CHANGES:
status.log_status(conn, start, 'import')
batchdate, _, _ = status.get_status(conn)
conn.close()