eth/tracers/js: consistent name for method receivers (#29375)

This commit is contained in:
Brandon Liu 2024-03-29 00:35:40 +08:00 committed by GitHub
parent 0183c7ad82
commit a3829178af
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 11 additions and 11 deletions

View File

@ -677,11 +677,11 @@ func (mo *memoryObj) Length() int {
return len(mo.memory)
}
func (m *memoryObj) setupObject() *goja.Object {
o := m.vm.NewObject()
o.Set("slice", m.vm.ToValue(m.Slice))
o.Set("getUint", m.vm.ToValue(m.GetUint))
o.Set("length", m.vm.ToValue(m.Length))
func (mo *memoryObj) setupObject() *goja.Object {
o := mo.vm.NewObject()
o.Set("slice", mo.vm.ToValue(mo.Slice))
o.Set("getUint", mo.vm.ToValue(mo.GetUint))
o.Set("length", mo.vm.ToValue(mo.Length))
return o
}
@ -863,12 +863,12 @@ func (co *contractObj) GetInput() goja.Value {
return res
}
func (c *contractObj) setupObject() *goja.Object {
o := c.vm.NewObject()
o.Set("getCaller", c.vm.ToValue(c.GetCaller))
o.Set("getAddress", c.vm.ToValue(c.GetAddress))
o.Set("getValue", c.vm.ToValue(c.GetValue))
o.Set("getInput", c.vm.ToValue(c.GetInput))
func (co *contractObj) setupObject() *goja.Object {
o := co.vm.NewObject()
o.Set("getCaller", co.vm.ToValue(co.GetCaller))
o.Set("getAddress", co.vm.ToValue(co.GetAddress))
o.Set("getValue", co.vm.ToValue(co.GetValue))
o.Set("getInput", co.vm.ToValue(co.GetInput))
return o
}