From 969f4bdfb7c40048283f7bbef488fc135712a712 Mon Sep 17 00:00:00 2001 From: TeoV Date: Tue, 2 Feb 2021 09:54:08 +0200 Subject: [PATCH] Update migrator to set correctly version for RouteS in case of NO_MORE_DATA error --- migrator/routes.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/migrator/routes.go b/migrator/routes.go index de5296ee9..82f79de52 100644 --- a/migrator/routes.go +++ b/migrator/routes.go @@ -89,12 +89,12 @@ func (m *Migrator) migrateFromSupplierToRoute() (err error) { if err := m.dmOut.DataManager().SetRouteProfile(convertSupplierToRoute(spp), true); err != nil { return err } - m.stats[utils.DerivedChargersV]++ + m.stats[utils.Routes]++ } if m.dryRun { return } - if err = m.removeSupplier(); err != nil { + if err = m.removeSupplier(); err != nil && err != utils.ErrNoMoreData { return } // All done, update version with current one