refactor: change NewStorageLocationProvider to use a splat for locationTypes
This commit is contained in:
parent
62bc189678
commit
ee20d2a560
|
@ -319,7 +319,7 @@ func (s *StorageLocationProviderImpl) Downvote(uri interfaces.SignedStorageLocat
|
||||||
return nil
|
return nil
|
||||||
}
|
}
|
||||||
|
|
||||||
func NewStorageLocationProvider(node interfaces.Node, hash *encoding.Multihash, locationTypes []types.StorageLocationType) interfaces.StorageLocationProvider {
|
func NewStorageLocationProvider(node interfaces.Node, hash *encoding.Multihash, locationTypes ...types.StorageLocationType) interfaces.StorageLocationProvider {
|
||||||
if locationTypes == nil {
|
if locationTypes == nil {
|
||||||
locationTypes = []types.StorageLocationType{
|
locationTypes = []types.StorageLocationType{
|
||||||
types.StorageLocationTypeFull,
|
types.StorageLocationTypeFull,
|
||||||
|
|
Loading…
Reference in New Issue