Skip to content

Commit c6db71b

Browse files
committed
removed mutex
1 parent 1cec3a8 commit c6db71b

File tree

1 file changed

+0
-7
lines changed

1 file changed

+0
-7
lines changed

httpclient/timeouts.go

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,22 +1,15 @@
11
package httpclient
22

33
import (
4-
"sync"
54
"time"
65
)
76

8-
var mu sync.Mutex
9-
107
// Amends the HTTP timeout time
118
func (c *Client) ModifyHttpTimeout(newTimeout time.Duration) {
12-
mu.Lock()
13-
defer mu.Unlock()
149
c.http.Timeout = newTimeout
1510
}
1611

1712
// Resets HTTP timeout time back to 10 seconds
1813
func (c *Client) ResetTimeout() {
19-
mu.Lock()
20-
defer mu.Unlock()
2114
c.http.Timeout = DefaultTimeout
2215
}

0 commit comments

Comments
 (0)