contrib/promexporter/exporters/relayer.go
Method exporter.fetchRelayerBalances
has 54 lines of code (exceeds 50 allowed). Consider refactoring. Open
Open
func (e *exporter) fetchRelayerBalances(ctx context.Context, url string) error {
// Fetch relayer addresses
quotes, err := e.fetchAllQuotes(ctx, url)
if err != nil {
return fmt.Errorf("could not fetch relayer addresses: %w", err)
Method exporter.fetchAllQuotes
has 5 return statements (exceeds 4 allowed). Open
Open
func (e *exporter) fetchAllQuotes(ctx context.Context, url string) ([]rfqAPIModel.GetQuoteResponse, error) {
req, err := http.NewRequestWithContext(ctx, http.MethodGet, url, nil)
if err != nil {
return nil, fmt.Errorf("could not get quotes: %w", err)
}