fix: nil pointer dereference

This commit is contained in:
Fu Diwei 2025-02-08 21:30:35 +08:00
parent 886f166e66
commit b9e28db089

View File

@ -53,7 +53,7 @@ func (n *deployNode) Process(ctx context.Context) error {
} }
// 检测是否可以跳过本次执行 // 检测是否可以跳过本次执行
if certificate.CreatedAt.Before(lastOutput.UpdatedAt) { if lastOutput != nil && certificate.CreatedAt.Before(lastOutput.UpdatedAt) {
if skippable, skipReason := n.checkCanSkip(ctx, lastOutput); skippable { if skippable, skipReason := n.checkCanSkip(ctx, lastOutput); skippable {
n.AddOutput(ctx, n.node.Name, skipReason) n.AddOutput(ctx, n.node.Name, skipReason)
return nil return nil