We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 151d763 commit a9ba250Copy full SHA for a9ba250
schema.graphql
@@ -196,6 +196,7 @@ type Swap @entity {
196
197
# populated from the Swap event
198
sender: Bytes!
199
+ from: Bytes! # the EOA that initiated the txn
200
amount0In: BigDecimal!
201
amount1In: BigDecimal!
202
amount0Out: BigDecimal!
src/mappings/core.ts
@@ -488,6 +488,7 @@ export function handleSwap(event: Swap): void {
488
swap.amount0Out = amount0Out
489
swap.amount1Out = amount1Out
490
swap.to = event.params.to
491
+ swap.from = event.transaction.from
492
swap.logIndex = event.logIndex
493
// use the tracked amount if we have it
494
swap.amountUSD = trackedAmountUSD === ZERO_BD ? derivedAmountUSD : trackedAmountUSD
0 commit comments