fix crash when calling MEV rpc with MEV disabled (#4389)
Avoid `/eth/v1/beacon/blinded_blocks` crash without `--payload-builder`.
This commit is contained in:
parent
55a95bca3c
commit
996a0bdcdc
|
@ -48,6 +48,9 @@ proc unblindAndRouteBlockMEV*(
|
|||
Future[Result[Opt[BlockRef], string]] {.async.} =
|
||||
# By time submitBlindedBlock is called, must already have done slashing
|
||||
# protection check
|
||||
if node.payloadBuilderRestClient.isNil:
|
||||
return err "unblindAndRouteBlockMEV: nil REST client"
|
||||
|
||||
let unblindedPayload =
|
||||
try:
|
||||
awaitWithTimeout(
|
||||
|
|
Loading…
Reference in New Issue