From 2409fee97f22bc3d7f963ca67059bc3383da18bc Mon Sep 17 00:00:00 2001 From: "W. Trevor King" Date: Wed, 29 Apr 2015 09:10:25 -0700 Subject: [PATCH] util/testutil/addcat: importer.BuildDagFromReader -> unixfs.AddFromReader The defaults used by the high-level wrapper are fine here, and we're in a test so consuming shell/... is ok. --- util/testutil/addcat/addcat.go | 9 ++------- 1 file changed, 2 insertions(+), 7 deletions(-) diff --git a/util/testutil/addcat/addcat.go b/util/testutil/addcat/addcat.go index f243aa372a7..4786a9f1f91 100644 --- a/util/testutil/addcat/addcat.go +++ b/util/testutil/addcat/addcat.go @@ -6,17 +6,12 @@ import ( core "github.com/ipfs/go-ipfs/core" coreunix "github.com/ipfs/go-ipfs/core/coreunix" - importer "github.com/ipfs/go-ipfs/importer" - chunk "github.com/ipfs/go-ipfs/importer/chunk" + unixfs "github.com/ipfs/go-ipfs/shell/unixfs" errors "github.com/ipfs/go-ipfs/util/debugerror" ) func AddCat(adder *core.IpfsNode, catter *core.IpfsNode, data string) error { - dagNode, err := importer.BuildDagFromReader( - strings.NewReader(data), - adder.DAG, - adder.Pinning.GetManual(), - chunk.DefaultSplitter) + dagNode, err := unixfs.AddFromReader(adder, strings.NewReader(data)) if err != nil { return err }