@@ -936,13 +936,7 @@ func (m *ApiService) processSingleValidator(idx int, valPubKey string, resultsCh
936936 return
937937 }
938938
939- // If the validator is or has been registered, the relayer will return a 200 message
940- // with the signed registration message. If the validator has never been registered,
941- // the relayer will return code 400 or 404 (depending on the relay) with the following message:
942- // {
943- // "code": 404,
944- // "message": "no registration found for validator 0xafcdacfb67396a41a72676f3b064bcf62e977e5ef1d8aebadeed06e97156d4f640516fb205d12211ada9a54fcc26cc58"
945- // }
939+ // If the validator is or has been registered, the relayer will return a 200 message with the signed registration message.
946940 // https://flashbots.github.io/relay-specs/#/Data/getValidatorRegistration
947941 if resp .StatusCode == http .StatusOK {
948942 signedRegistration := & builderApiV1.SignedValidatorRegistration {}
@@ -961,25 +955,20 @@ func (m *ApiService) processSingleValidator(idx int, valPubKey string, resultsCh
961955 Timestamp : fmt .Sprintf ("%d" , signedRegistration .Message .Timestamp .UnixNano ()),
962956 }
963957
964- // If the fee recipient matches the pool address, the relayer is registered
958+ // If the fee recipient matches the pool address, the relayer is registered with the correct fee recipient (the smoothing pool one)
965959 if utils .Equals (signedRegistration .Message .FeeRecipient .String (), m .Onchain .PoolAddress ) {
966960 correctFeeRelays = append (correctFeeRelays , relayRegistration )
967961 } else {
968962 // if the fee recipient does not match the pool address, the relayer is registered but with the wrong fee recipient
969963 wrongFeeRelays = append (wrongFeeRelays , relayRegistration )
970964 }
971965
972- // else if (signedRegistration.Message.FeeRecipient.String() != m.Onchain.PoolAddress) && (signedRegistration.Message.FeeRecipient.String() != "") {
973- // // If the fee recipient does not match the pool address, the relayer is registered but with the wrong fee recipient
974- // wrongFeeRelays = append(wrongFeeRelays, relayRegistration)
975- // }
976-
977966 } else if resp .StatusCode == http .StatusBadRequest || resp .StatusCode == http .StatusNotFound {
978- // the validator is not registered with the relayer
967+ // If the validator has never been registered, the relayer will return code 400 or 404 (depending on the relay)
979968 unregisteredRelays = append (unregisteredRelays , httpRelay {RelayAddress : relay })
980969 } else {
981- // there was an error calling the relayer, so we couldnt check if the validator is/was registered with the correct
982- // fee recipient, so we return an error.
970+ // If we get here, the relayer had an internal server error , so we couldnt check if the validator is/was registered with the correct
971+ // fee recipient. We return an error.
983972 resultsChan <- ValidatorRelayResult {
984973 Index : idx ,
985974 Err : fmt .Errorf ("error calling relayer %s for validator %s: %v" , relay , valPubKey , string (bodyBytes )),
0 commit comments