0

This is where I am calling the contract

function certify_find (hash, callback) {
   contract.methods.findDocHash(hash).call( function (error, result) {
   if (error) {
    console.log("Returned ERROR from findDocHash");
    callback(error, null);
  }else {
    let resultObj = {
      mineTime:  new Date(result[0] * 1000),
      blockNumber: result[1],
      instituteName: result[2],
      recipientName: result[3],
      courseName: result[4],
      marks: result[5],
      dateOfCompletion: result[6]
    }
    callback(null, resultObj);
   }
 });
};

Publishing into the blockchain is working perfectly. Only this is not working. This is my genesis.json file

{
    "config": {
      "chainId": 143,
      "homesteadBlock": 0,
      "eip150Block": 0,
      "eip155Block": 0,
      "eip158Block": 0  
    },
    "alloc": {},
    "difficulty" : "0x20000",
    "gasLimit"   : "0x8880000"
}

Please help me!!

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.