executor: reuse taskPath function

This commit is contained in:
Simone Gotti 2019-06-12 16:16:53 +02:00
parent 48411f4c64
commit 629cf2be82
1 changed files with 1 additions and 1 deletions

View File

@ -1163,7 +1163,7 @@ func (e *Executor) tasksDataCleaner(ctx context.Context) error {
}
}
if resp.StatusCode == http.StatusNotFound {
taskDir := filepath.Join(e.tasksDir(), entry.Name())
taskDir := e.taskPath(etID)
log.Infof("removing task dir %q", taskDir)
// remove task dir
if err := os.RemoveAll(taskDir); err != nil {