Skip to content

Commit

Permalink
hinted indexed map size
Browse files Browse the repository at this point in the history
  • Loading branch information
ganigeorgiev committed Dec 20, 2022
1 parent 15c05b9 commit 3449084
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion models/record.go
Original file line number Diff line number Diff line change
Expand Up @@ -174,7 +174,7 @@ func (m *Record) MergeExpand(expand map[string]any) {
continue
}

oldIndexed := map[string]*Record{}
oldIndexed := make(map[string]*Record, len(oldSlice))
for _, oldRecord := range oldSlice {
oldIndexed[oldRecord.Id] = oldRecord
}
Expand Down

0 comments on commit 3449084

Please sign in to comment.