replaced with ==.
This commit is contained in:
parent
8826654764
commit
6a3ebcebd2
|
@ -1,6 +1,5 @@
|
|||
import { Order, OrderReuse } from '../../@types/schema'
|
||||
import { log } from '@graphprotocol/graph-ts'
|
||||
import { toChecksumAddress } from 'ethereumjs-util'
|
||||
|
||||
export function getOrderId(
|
||||
tx: string,
|
||||
|
@ -53,21 +52,19 @@ export function searchOrderForEvent(
|
|||
)
|
||||
log.info('orderId as trial: {}', [orderId])
|
||||
const order = Order.load(orderId)
|
||||
if (
|
||||
order !== null &&
|
||||
toChecksumAddress(order.datatoken) === toChecksumAddress(address)
|
||||
) {
|
||||
if (order !== null && order.datatoken == address) {
|
||||
log.info('order datatoken: {}', [order.datatoken])
|
||||
log.info('event address: {}', [address])
|
||||
log.info('typeof order datatoken: {}', [typeof order.datatoken])
|
||||
log.info('typeof hex event address: {}', [typeof address])
|
||||
// add break
|
||||
return getOrder(
|
||||
transactionHash,
|
||||
address,
|
||||
transactionFrom,
|
||||
firstEventIndex
|
||||
)
|
||||
// return getOrder(
|
||||
// transactionHash,
|
||||
// address,
|
||||
// transactionFrom,
|
||||
// firstEventIndex
|
||||
// )
|
||||
return order
|
||||
}
|
||||
firstEventIndex--
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue