diff --git a/gateways.go b/gateways.go index 7020b96fb8788044a45860b649ee104184b7a437..f37c1253aa83a8acb04edf8dfdb135c0dbaa44af 100644 --- a/gateways.go +++ b/gateways.go @@ -22,6 +22,10 @@ import ( "net/http" ) +const ( + eipAPI = "/3/config/eip-service.json" +) + type bonafide struct { client *http.Client eip *eipService @@ -52,8 +56,11 @@ type coordinates struct { func newBonafide(apiDomain string) *bonafide { client := &http.Client{} - eipAPI := apiDomain + "/3/config/eip-service.json" - return &bonafide{client, nil, eipAPI} + api := apiDomain + eipAPI + return &bonafide{ + client: client, + eipAPI: api, + } } func (b *bonafide) getGateways() ([]gateway, error) {