This commit is contained in:
shoopea 2020-10-20 11:31:29 +02:00
parent 56fe67649a
commit ea26736eba

8
sql.go
View File

@ -1013,12 +1013,16 @@ func cleanupJobData() {
}
log.Printf("cleanupJobData : JobID : %d\n", jobID)
err = doneStmt.QueryRow(jobID).Scan(&isDone)
logOnError(err, "cleanupJobData : scan doneStmt")
if err != nil {
if err.Error() == `sql: no rows in result set` {
delObj, err := delObjStmt.Exec(jobID)
logOnError(err, "cleanupJobData : exec delObjStmt")
if err != nil {
return
}
} else {
logOnError(err, "cleanupJobData : scan doneStmt")
return
}
} else {