diff options
| author | nytpu <alex@nytpu.com> | 2021-03-23 08:53:06 -0600 |
|---|---|---|
| committer | nytpu <alex@nytpu.com> | 2021-03-23 08:53:06 -0600 |
| commit | 76f25b7708c18a3225cff45b9f7f56c089679732 (patch) | |
| tree | 22cad796f621a03026d736e98f54776986432025 /fetch/gemini.go | |
| parent | 51833063506e1f342e2a7efd2dbe81f04ebb3757 (diff) | |
Fix bug in co refresh where contexts would be immediately cancelled
Diffstat (limited to 'fetch/gemini.go')
| -rw-r--r-- | fetch/gemini.go | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/fetch/gemini.go b/fetch/gemini.go index 5f26b95..0fbb3ec 100644 --- a/fetch/gemini.go +++ b/fetch/gemini.go @@ -28,8 +28,7 @@ import ( // fetchGemini will make a request for a gemini resource func fetchGemini(remote string) (*gemini.Response, error) { - ctx, cancel := context.WithTimeout(context.Background(), time.Duration(core.Timeout)*time.Second) - defer cancel() + ctx, _ := context.WithTimeout(context.Background(), time.Duration(core.Timeout)*time.Second) client := &gemini.Client{} resp, err := client.Get(ctx, remote) if err != nil { |
