Skip to content

Commit

Permalink
rpc: update docstring (ethereum#26072)
Browse files Browse the repository at this point in the history
Co-authored-by: seven <seven@nodereal.io>
  • Loading branch information
2 people authored and roberto-bayardo committed Oct 31, 2022
1 parent 9d58c4b commit cf3375b
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions rpc/types.go
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ const (
)

// UnmarshalJSON parses the given JSON fragment into a BlockNumber. It supports:
// - "latest", "earliest" or "pending" as string arguments
// - "safe", "finalized", "latest", "earliest" or "pending" as string arguments
// - the block number
// Returned errors:
// - an invalid block number error when the given argument isn't a known strings
Expand Down Expand Up @@ -110,7 +110,7 @@ func (bn *BlockNumber) UnmarshalJSON(data []byte) error {
}

// MarshalText implements encoding.TextMarshaler. It marshals:
// - "latest", "earliest" or "pending" as strings
// - "safe", "finalized", "latest", "earliest" or "pending" as strings
// - other numbers as hex
func (bn BlockNumber) MarshalText() ([]byte, error) {
switch bn {
Expand Down

0 comments on commit cf3375b

Please sign in to comment.