mirror of
https://github.com/oceanprotocol/ocean.js.git
synced 2024-11-26 20:39:05 +01:00
moved all address checks to lowercase
This commit is contained in:
parent
dfceb09d5e
commit
a82a8e6a86
@ -448,7 +448,7 @@ export class OceanPool extends Pool {
|
|||||||
})
|
})
|
||||||
|
|
||||||
for (let i = 0; i < events.length; i++) {
|
for (let i = 0; i < events.length; i++) {
|
||||||
if (!account || events[i].returnValues[0] === account)
|
if (!account || events[i].returnValues[0].toLowerCase() === account.toLowerCase())
|
||||||
results.push(await this.getEventData('swap', poolAddress, dtAddress, events[i]))
|
results.push(await this.getEventData('swap', poolAddress, dtAddress, events[i]))
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -459,7 +459,7 @@ export class OceanPool extends Pool {
|
|||||||
})
|
})
|
||||||
|
|
||||||
for (let i = 0; i < events.length; i++) {
|
for (let i = 0; i < events.length; i++) {
|
||||||
if (!account || events[i].returnValues[0] === account)
|
if (!account || events[i].returnValues[0].toLowerCase() === account.toLowerCase())
|
||||||
results.push(await this.getEventData('join', poolAddress, dtAddress, events[i]))
|
results.push(await this.getEventData('join', poolAddress, dtAddress, events[i]))
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -469,7 +469,7 @@ export class OceanPool extends Pool {
|
|||||||
toBlock: 'latest'
|
toBlock: 'latest'
|
||||||
})
|
})
|
||||||
for (let i = 0; i < events.length; i++) {
|
for (let i = 0; i < events.length; i++) {
|
||||||
if (!account || events[i].returnValues[0] === account)
|
if (!account || events[i].returnValues[0].toLowerCase() === account.toLowerCase())
|
||||||
results.push(await this.getEventData('exit', poolAddress, dtAddress, events[i]))
|
results.push(await this.getEventData('exit', poolAddress, dtAddress, events[i]))
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -377,7 +377,7 @@ export class OceanFixedRateExchange {
|
|||||||
toBlock: 'latest'
|
toBlock: 'latest'
|
||||||
})
|
})
|
||||||
for (let i = 0; i < events.length; i++) {
|
for (let i = 0; i < events.length; i++) {
|
||||||
if (!account || events[i].returnValues[3] === account)
|
if (!account || events[i].returnValues[3].toLowerCase() === account.toLowerCase())
|
||||||
result.push(await this.getExchange(events[i].returnValues[0]))
|
result.push(await this.getExchange(events[i].returnValues[0]))
|
||||||
}
|
}
|
||||||
return result
|
return result
|
||||||
@ -400,7 +400,7 @@ export class OceanFixedRateExchange {
|
|||||||
toBlock: 'latest'
|
toBlock: 'latest'
|
||||||
})
|
})
|
||||||
for (let i = 0; i < events.length; i++) {
|
for (let i = 0; i < events.length; i++) {
|
||||||
if (!account || events[i].returnValues[1] === account)
|
if (!account || events[i].returnValues[1].toLowerCase() === account.toLowerCase())
|
||||||
result.push(this.getEventData(events[i]))
|
result.push(this.getEventData(events[i]))
|
||||||
}
|
}
|
||||||
return result
|
return result
|
||||||
|
Loading…
x
Reference in New Issue
Block a user