Skip to content

Commit

Permalink
Fix lint
Browse files Browse the repository at this point in the history
  • Loading branch information
islamaliev committed Mar 7, 2024
1 parent 4a2b0f7 commit be811d8
Show file tree
Hide file tree
Showing 3 changed files with 18 additions and 4 deletions.
6 changes: 5 additions & 1 deletion db/collection_index.go
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,11 @@ func (db *db) fetchCollectionIndexDescriptions(
return indexDescriptions, nil
}

func (db *db) getCollectionIndexes(ctx context.Context, txn datastore.Txn, col client.Collection) ([]CollectionIndex, error) {
func (db *db) getCollectionIndexes(
ctx context.Context,
txn datastore.Txn,
col client.Collection,
) ([]CollectionIndex, error) {
indexDescriptions, err := db.fetchCollectionIndexDescriptions(ctx, txn, col.ID())
if err != nil {
return nil, err
Expand Down
13 changes: 11 additions & 2 deletions net/server.go
Original file line number Diff line number Diff line change
Expand Up @@ -327,7 +327,11 @@ func (s *server) PushLog(ctx context.Context, req *pb.PushLogRequest) (*pb.PushL
return &pb.PushLogReply{}, client.NewErrMaxTxnRetries(txnErr)
}

func (*server) getActiveCollection(ctx context.Context, store client.Store, schemaRoot string) (client.Collection, error) {
func (*server) getActiveCollection(
ctx context.Context,
store client.Store,
schemaRoot string,
) (client.Collection, error) {
cols, err := store.GetCollections(
ctx,
client.CollectionFetchOptions{
Expand All @@ -350,7 +354,12 @@ func (*server) getActiveCollection(ctx context.Context, store client.Store, sche
return col, nil
}

func (s *server) syncIndexedDocs(ctx context.Context, col client.Collection, docID client.DocID, store client.Store) error {
func (s *server) syncIndexedDocs(
ctx context.Context,
col client.Collection,
docID client.DocID,
store client.Store,
) error {
preTxnCol, err := s.db.GetCollectionByName(ctx, col.Name().Value())
if err != nil {
return err
Expand Down
3 changes: 2 additions & 1 deletion tests/integration/index/index_p2p_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,9 @@ package index
import (
"testing"

testUtils "github.com/sourcenetwork/defradb/tests/integration"
"github.com/sourcenetwork/immutable"

testUtils "github.com/sourcenetwork/defradb/tests/integration"
)

func TestIndexP2P_IfPeerCreatedDoc_ListeningPeerShouldIndexIt(t *testing.T) {
Expand Down

0 comments on commit be811d8

Please sign in to comment.