refactor: clean code

This commit is contained in:
Fu Diwei
2025-04-28 12:09:28 +08:00
parent 92c93822b9
commit edaf08361f
3 changed files with 12 additions and 12 deletions

View File

@@ -39,11 +39,11 @@ func (n *uploadNode) Process(ctx context.Context) error {
}
// 检测是否可以跳过本次执行
if skippable, skipReason := n.checkCanSkip(ctx, lastOutput); skippable {
n.logger.Info(fmt.Sprintf("skip this upload, because %s", skipReason))
if skippable, reason := n.checkCanSkip(ctx, lastOutput); skippable {
n.logger.Info(fmt.Sprintf("skip this upload, because %s", reason))
return nil
} else if skipReason != "" {
n.logger.Info(fmt.Sprintf("re-upload, because %s", skipReason))
} else if reason != "" {
n.logger.Info(fmt.Sprintf("re-upload, because %s", reason))
}
// 生成证书实体