Skip to content

Commit

Permalink
chore: replace for loop with call to copy (#2678)
Browse files Browse the repository at this point in the history
  • Loading branch information
testwill authored Nov 30, 2023
1 parent 68c026c commit 252385e
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions util/sync/options.go
Original file line number Diff line number Diff line change
Expand Up @@ -23,9 +23,7 @@ type Option func(o *Options)
func Stores(stores ...store.Store) Option {
return func(o *Options) {
o.Stores = make([]store.Store, len(stores))
for i, s := range stores {
o.Stores[i] = s
}
copy(o.Stores, stores)
}
}

Expand Down

0 comments on commit 252385e

Please sign in to comment.