Adder: make sure we always pin recursively after adding
Regardless of the Mode option.
This commit is contained in:
parent
edd91f35ae
commit
ddea1a995c
|
@ -36,6 +36,8 @@ type DAGService struct {
|
||||||
// New returns a new Adder with the given rpc Client. The client is used
|
// New returns a new Adder with the given rpc Client. The client is used
|
||||||
// to perform calls to IPFS.BlockPut and Pin content on Cluster.
|
// to perform calls to IPFS.BlockPut and Pin content on Cluster.
|
||||||
func New(rpc *rpc.Client, opts api.PinOptions, local bool) *DAGService {
|
func New(rpc *rpc.Client, opts api.PinOptions, local bool) *DAGService {
|
||||||
|
// ensure don't Add something and pin it in direct mode.
|
||||||
|
opts.Mode = api.PinModeRecursive
|
||||||
return &DAGService{
|
return &DAGService{
|
||||||
rpcClient: rpc,
|
rpcClient: rpc,
|
||||||
dests: nil,
|
dests: nil,
|
||||||
|
|
Loading…
Reference in New Issue
Block a user