我有一份ethers
与我进行交易的合同:
const randomSVG = new ethers.Contract(RandomSVG.address, RandomSVGContract.interface, signer)
let tx = await randomSVG.create()
我有一个与此交易有关的事件:
function create() public returns (bytes32 requestId) {
requestId = requestRandomness(keyHash, fee);
emit requestedRandomSVG(requestId);
}
但是,我在交易收据中看不到日志。]( https://docs.ethers.io/v5/api/providers/types/#providers-TransactionReceipt )
// This returns undefined
console.log(tx.logs)