Skip to content

Commit

Permalink
Currectly compare generation; Always assign
Browse files Browse the repository at this point in the history
Signed-off-by: Arnob kumar saha <arnob@appscode.com>
  • Loading branch information
ArnobKumarSaha committed Oct 9, 2024
1 parent 319b68c commit 341f634
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions client/client.go
Original file line number Diff line number Diff line change
Expand Up @@ -116,10 +116,10 @@ func CreateOrPatch(ctx context.Context, c client.Client, obj client.Object, tran
}

vt := kutil.VerbUnchanged
if obj.GetGeneration() != mod.GetGeneration() {
if cur.GetGeneration() != mod.GetGeneration() {
vt = kutil.VerbPatched
assign(obj, mod)
}
assign(obj, mod)
return vt, nil
}

Expand Down

0 comments on commit 341f634

Please sign in to comment.