From ae9726f747b2ec3e5805d03ef04ad47cb7628315 Mon Sep 17 00:00:00 2001 From: kaotisk Date: Mon, 10 Jun 2024 05:08:59 +0300 Subject: Refactoring --- api/routes/announceZChain/index.js | 22 +--------------------- 1 file changed, 1 insertion(+), 21 deletions(-) (limited to 'api/routes/announceZChain') diff --git a/api/routes/announceZChain/index.js b/api/routes/announceZChain/index.js index 91ac5b9..a1b336c 100644 --- a/api/routes/announceZChain/index.js +++ b/api/routes/announceZChain/index.js @@ -1,23 +1,3 @@ -/* - * After NS validation went through we examine the return code - * of the application that run the test. - * - * Returns: - * - error on failure - * - on success we process with addNSEntriesToFile() - * - */ -function continuethingsNS(validitycode,sh,res,gotit){ - if (validitycode === 0){ - var entry = { - zchain: sh, - latest: JSON.parse(gotit).Path.replace('/ipfs/','') - }; - addNSEntriesToFile(entry,res); - } else { - res.send({error:"Invalid data"}); - } -} /* * Accepts a zchain * @@ -32,7 +12,7 @@ function continuethingsNS(validitycode,sh,res,gotit){ * function getNSvalidity() * */ -const getNSvalidity = require('../../validators/ZchainValidator') +const getNSvalidity = require('../../validators/ZchainValidator'); module.exports = (req, res) => { console.log(req); -- cgit v1.2.3