Skip to content

Commit

Permalink
remove redundant check that could never occur
Browse files Browse the repository at this point in the history
  • Loading branch information
letFunny committed Jul 10, 2024
1 parent e16eb2e commit eff44b1
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions internal/setup/setup.go
Original file line number Diff line number Diff line change
Expand Up @@ -208,8 +208,7 @@ func (r *Release) validate() error {
}

checkConflict := func(old, new pathSlice) error {
// fast path for when the paths match.
if old.path == new.path || strdist.GlobPath(new.path, old.path) {
if strdist.GlobPath(new.path, old.path) {
if (old.slice.Package > new.slice.Package) || (old.slice.Package == new.slice.Package && old.slice.Name > new.slice.Name) {
old, new = new, old
}
Expand Down

0 comments on commit eff44b1

Please sign in to comment.