fix: use queue in the retry timer

This commit is contained in:
jubb 2021-03-16 09:44:55 +11:00
parent fe3f3d5f88
commit dd8a0cdc2e

View File

@ -80,7 +80,7 @@ class JobQueue : JobDelegate {
Log.i("Jobs", "${job::class.simpleName} failed; scheduling retry (failure count is ${job.failureCount}).") Log.i("Jobs", "${job::class.simpleName} failed; scheduling retry (failure count is ${job.failureCount}).")
Timer().schedule(delay = retryInterval) { Timer().schedule(delay = retryInterval) {
Log.i("Jobs", "Retrying ${job::class.simpleName}.") Log.i("Jobs", "Retrying ${job::class.simpleName}.")
job.execute() queue.offer(job)
} }
} }
} }