Skip to content

Commit

Permalink
fix client and readme
Browse files Browse the repository at this point in the history
  • Loading branch information
Danny-Dasilva committed Nov 28, 2023
1 parent 9bce706 commit db851c4
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 3 deletions.
4 changes: 3 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -130,8 +130,9 @@ func main() {
}

```
#### Example using your own custom http.Client

## Example using your own custom http.Client
<details>

```go
import (
Expand All @@ -151,6 +152,7 @@ func main() {
...
}
```
</details>

## Creating an instance

Expand Down
4 changes: 2 additions & 2 deletions cycletls/client.go
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ func clientBuilder(browser Browser, dialer proxy.ContextDialer, timeout int, dis
//
// cycleClient.Get("https://tls.peet.ws/")
func NewTransport(ja3 string, useragent string) http.RoundTripper {
return newRoundTripper(browser{
return newRoundTripper(Browser{
JA3: ja3,
UserAgent: useragent,
})
Expand All @@ -65,7 +65,7 @@ func NewTransport(ja3 string, useragent string) http.RoundTripper {
// NewTransport creates a new HTTP client transport that modifies HTTPS requests
// to imitiate a specific JA3 hash and User-Agent, optionally specifying a proxy via proxy.ContextDialer.
func NewTransportWithProxy(ja3 string, useragent string, proxy proxy.ContextDialer) http.RoundTripper {
return newRoundTripper(browser{
return newRoundTripper(Browser{
JA3: ja3,
UserAgent: useragent,
}, proxy)
Expand Down

0 comments on commit db851c4

Please sign in to comment.