Merge pull request #9566 from qyqcswill/code_simplify

code simplify
This commit is contained in:
Wenkai Yin(尹文开) 2019-10-25 13:15:50 +08:00 committed by GitHub
commit 91bc57d695
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -351,8 +351,5 @@ func UpdateTaskStatus(id int64, status string, statusRevision int64, statusCondi
}
func taskFinished(status string) bool {
if status == models.TaskStatusFailed || status == models.TaskStatusStopped || status == models.TaskStatusSucceed {
return true
}
return false
return status == models.TaskStatusFailed || status == models.TaskStatusStopped || status == models.TaskStatusSucceed
}