From d2b203bc71082604c20946530206b7491faa8122 Mon Sep 17 00:00:00 2001 From: Volker Mische Date: Thu, 22 Feb 2018 14:20:49 +0100 Subject: [PATCH] fix(dag): path logic for DAG get was wrong --- src/dag/get.js | 13 +------------ 1 file changed, 1 insertion(+), 12 deletions(-) diff --git a/src/dag/get.js b/src/dag/get.js index af3fa55e7..989d5373b 100644 --- a/src/dag/get.js +++ b/src/dag/get.js @@ -20,23 +20,12 @@ module.exports = (send) => { } options = options || {} + path = path || '' if (CID.isCID(cid)) { cid = cid.toBaseEncodedString() } - if (typeof cid === 'string') { - const split = cid.split('/') - cid = split[0] - split.shift() - - if (split.length > 0) { - path = split.join('/') - } else { - path = '/' - } - } - waterfall([ cb => { send({