Skip to content

Commit

Permalink
fix apply check
Browse files Browse the repository at this point in the history
  • Loading branch information
floreks committed Jul 2, 2024
1 parent 37fed4d commit 91bb9b6
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion pkg/cache/sha.go
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,11 @@ func (in SHA) SetManifestSHA(manifestSHA string) {
// or between last two manifestSHA read from the repository.
// If any drift is detected, then server-side apply should be done.
func (in SHA) RequiresApply(manifestSHA string) bool {
return (*in.serverSHA != *in.applySHA) || (manifestSHA != *in.manifestSHA)
return in.serverSHA == nil ||
in.applySHA == nil ||
in.manifestSHA == nil ||
(*in.serverSHA != *in.applySHA) ||
(manifestSHA != *in.manifestSHA)
}

// shaObject is a representation of a resource used to calculate SHA from.
Expand Down

0 comments on commit 91bb9b6

Please sign in to comment.