mirror of
https://github.com/Rain-kl/OpenFlare.git
synced 2026-09-29 14:06:36 +08:00
代码质量优化
This commit is contained in:
@@ -19,6 +19,7 @@ package task
|
||||
|
||||
import (
|
||||
"context"
|
||||
"errors"
|
||||
"fmt"
|
||||
"time"
|
||||
|
||||
@@ -155,7 +156,7 @@ func RetryTask(ctx context.Context, id uint64) (string, error) {
|
||||
}
|
||||
|
||||
if !execution.Retryable {
|
||||
return "", fmt.Errorf(errTaskNotRetryable)
|
||||
return "", errors.New(errTaskNotRetryable)
|
||||
}
|
||||
|
||||
if execution.RetryCount >= execution.MaxRetry {
|
||||
|
||||
Reference in New Issue
Block a user