File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1+ Fix detecting burning events
Original file line number Diff line number Diff line change @@ -5,8 +5,8 @@ const NULL_ADDRESS = '0x0000000000000000000000000000000000000000'
55export function parseEvmEvent ( event : RuntimeEvent ) {
66 const fromAddress = event . evm_log_params ?. find ( param => param . name === 'from' ) ?. value as string | undefined
77 const toAddress = event . evm_log_params ?. find ( param => param . name === 'to' ) ?. value as string | undefined
8- const isMinting = fromAddress === NULL_ADDRESS
9- const isBurning = toAddress === NULL_ADDRESS
8+ const isMinting = event . evm_log_name === 'Transfer' && fromAddress === NULL_ADDRESS
9+ const isBurning = event . evm_log_name === 'Transfer' && toAddress === NULL_ADDRESS
1010 const parsedEvmLogName = isMinting ? 'Minting' : isBurning ? 'Burning' : event . evm_log_name || undefined
1111
1212 return {
You can’t perform that action at this time.
0 commit comments