src/IpfsService.js
/**
    * Search a node within the IPFS tree
    *
    * @param   {String}   ipfsHash    ipfs tree location
    * @param   {String}   search      target node's label
    * @param   {Boolean}  fetchData   retrieve node's data value or its location
    * @return  {Object}               the desired node with its childrens if it exists                                              
    */
Search a node within the IPFS tree
@param   {String}   ipfsHash    ipfs tree location
@param   {String}   search      target node's label
@param   {Boolean}  fetchData   retrieve node's data value or its location
@return  {Object}               the desired node with its childrens if it exists
Search a node within the IPFS tree @param { String } ipfsHash ipfs tree location @param { String } search target node ' s label @param { Boolean } fetchData retrieve node ' s data value or its location @return { Object } the desired node with its childrens if it exists
async searchNode(ipfsHash, search, fetchData = false, privateKey = null) {
        const tree = await this.getObject(ipfsHash)
        let result = IdentityDag.dfs(tree, search)
        if(result && fetchData) result = await this.fetchNodeData(result, privateKey)
        return result
    }
async searchNode ( ipfsHash , search , fetchData = false , privateKey = null ) { const tree = await this . getObject ( ipfsHash ) let result = IdentityDag . dfs ( tree , search ) if ( result && fetchData ) result = await this . fetchNodeData ( result , privateKey ) return result }
Search a node within the IPFS tree
 @param   {String}   ipfsHash    ipfs tree location
 @param   {String}   search      target node's label
 @param   {Boolean}  fetchData   retrieve node's data value or its location
 @return  {Object}               the desired node with its childrens if it exists
Search a node within the IPFS tree @param { String } ipfsHash ipfs tree location @param { String } search target node ' s label @param { Boolean } fetchData retrieve node ' s data value or its location @return { Object } the desired node with its childrens if it exists