Skip to content

Commit

Permalink
fix: Remove Global Variable
Browse files Browse the repository at this point in the history
  • Loading branch information
LeelaChacha committed Dec 29, 2024
1 parent 9d2348e commit dffabb9
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions internal/declarative/v2/reconciler.go
Original file line number Diff line number Diff line change
Expand Up @@ -35,10 +35,6 @@ var (
ErrResourceSyncDiffInSameOCILayer = errors.New("resource syncTarget diff detected but in " +
"same oci layer, prevent sync resource to be deleted")
errStateRequireUpdate = errors.New("manifest state requires update")

intendedRequeueErrors = map[error]struct{}{
skrresources.ErrWarningResourceSyncStateDiff: {},
}
)

const (
Expand Down Expand Up @@ -565,6 +561,10 @@ func (r *Reconciler) finishReconcile(ctx context.Context, manifest *v1beta2.Mani
}

func isIntendedRequeueError(err error) bool {
intendedRequeueErrors := map[error]struct{}{
skrresources.ErrWarningResourceSyncStateDiff: {},
}

_, ok := intendedRequeueErrors[err]
return ok
}
Expand Down

0 comments on commit dffabb9

Please sign in to comment.