Crashing on chunk retrieval fail.
This commit is contained in:
parent
3e601ea2cb
commit
3f0c3f61c5
|
@ -73,6 +73,8 @@ func mergeDatabases(pyDb *sql.DB, goDb persistence.Database) error {
|
||||||
chunk, err := old.GetTorrentsChunk(pyDb, lastId, *chunkSize)
|
chunk, err := old.GetTorrentsChunk(pyDb, lastId, *chunkSize)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
zap.L().Error("Error while getting torrents chunk", zap.Uint64("last-id", lastId))
|
zap.L().Error("Error while getting torrents chunk", zap.Uint64("last-id", lastId))
|
||||||
|
|
||||||
|
return err
|
||||||
}
|
}
|
||||||
|
|
||||||
if len(chunk) == 0 {
|
if len(chunk) == 0 {
|
||||||
|
|
Reference in a new issue