Skip to content

Commit

Permalink
Merge branch 'main' into cleanup-part-2
Browse files Browse the repository at this point in the history
  • Loading branch information
brianolson authored May 6, 2024
2 parents 7a8dbc1 + a65fd43 commit 1fc3ca2
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions client.go
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ package aptos

import (
"errors"
"net/http/cookiejar"
"net/url"
"time"
)
Expand Down Expand Up @@ -96,6 +97,15 @@ func NewClient(config NetworkConfig) (client *Client, err error) {
// TODO: add indexer

nodeClient := new(NodeClient)

// Set cookie jar so cookie stickiness applies to connections
// TODO Add appropriate suffix list
jar, err := cookiejar.New(nil)
if err != nil {
return nil, err
}

nodeClient.client.Jar = jar
nodeClient.baseUrl = *nodeUrl
nodeClient.client.Timeout = 60 * time.Second // TODO: Make configurable
faucetClient := &FaucetClient{
Expand Down

0 comments on commit 1fc3ca2

Please sign in to comment.