Skip to content

Commit

Permalink
Fix linter issue
Browse files Browse the repository at this point in the history
  • Loading branch information
zale144 committed Aug 29, 2024
1 parent 71d4f07 commit eee9efd
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 5 deletions.
1 change: 1 addition & 0 deletions order_client.go
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,7 @@ func newOrderClient(ctx context.Context, config Config) (*orderClient, error) {
return nil, fmt.Errorf("failed to create cosmos client: %w", err)
}

//nolint:gosec
subscriberID := fmt.Sprintf("eibc-client-%d", rand.Int())

orderCh := make(chan []*demandOrder, newOrderBufferSize)
Expand Down
3 changes: 1 addition & 2 deletions order_tracker.go
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@ package main
import (
"context"
"fmt"
"math/rand"
"strings"
"sync"

Expand Down Expand Up @@ -174,7 +173,7 @@ func (or *orderTracker) waitForFinalizedOrder(ctx context.Context) error {
// TODO: should filter by fulfiller (one of the bots)?
var query = fmt.Sprintf("%s.is_fulfilled='true' AND %s.new_packet_status='FINALIZED'", finalizedEvent, finalizedEvent)

resCh, err := or.client.RPC.Subscribe(ctx, fmt.Sprintf("eibc-client-%d", rand.Int()), query)
resCh, err := or.client.RPC.Subscribe(ctx, or.subscriberID, query)
if err != nil {
return fmt.Errorf("failed to subscribe to demand orders: %w", err)
}
Expand Down
4 changes: 1 addition & 3 deletions types/codec.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,4 @@ import (
cdctypes "github.com/cosmos/cosmos-sdk/codec/types"
)

var (
ModuleCdc = codec.NewProtoCodec(cdctypes.NewInterfaceRegistry())
)
var ModuleCdc = codec.NewProtoCodec(cdctypes.NewInterfaceRegistry())

0 comments on commit eee9efd

Please sign in to comment.