github.com/elastos/Elastos.ELA.SideChain.ETH@v0.2.2/oracle/getfaileddeposittransactionbyhash.js (about)

     1  "use strict";
     2  
     3  const common = require("./common");
     4  const child_process = require("child_process");
     5  
     6  module.exports = async function (json_data, res) {
     7      try {
     8          let hash = json_data["params"]["hash"];
     9          let failedTx = await common.web3.getFailedRechargeTxByHash(hash)
    10          res.json({"error": null, "id": null, "jsonrpc": "2.0", "result": failedTx});
    11          return;
    12      } catch (err) {
    13          console.log("failed deposit transaction by hash error==>", err);
    14          common.reterr(err, res);
    15          return;
    16      }
    17  }