Skip to content

Commit

Permalink
lint
Browse files Browse the repository at this point in the history
  • Loading branch information
rez1dent3 committed Jul 12, 2024
1 parent 9046fa0 commit b87ffd6
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion packer.go
Original file line number Diff line number Diff line change
Expand Up @@ -182,7 +182,7 @@ func (p *Packer) preferredSort(boxes boxSlice, items itemSlice) boxSlice {
// Returns:
// - a slice of items that did not fit into the box.
//
//nolint:funlen,gocognit,cyclop
//nolint:funlen,gocognit,cyclop,nestif
func (p *Packer) packToBox(b *Box, items []*Item) []*Item {
var fitted bool

Expand Down Expand Up @@ -243,6 +243,7 @@ func (p *Packer) packToBox(b *Box, items []*Item) []*Item {
// Check if item can be put in the box
if backup.PutItem(copyItems[k], backup.items[j].position) {
itemsFit++

break
}

Expand All @@ -266,6 +267,7 @@ func (p *Packer) packToBox(b *Box, items []*Item) []*Item {
// If item can be put in the box
if backup.PutItem(copyItems[k], pv) {
itemsFit++

break
}
}
Expand Down

0 comments on commit b87ffd6

Please sign in to comment.