Separate req.WithContext

This commit is contained in:
user 2018-08-06 16:46:06 +01:00
parent 6d0cba84e8
commit 0ccef5db53

View file

@ -69,7 +69,9 @@ func (a *AppServiceQueryAPI) RoomAliasExists(
if err != nil { if err != nil {
return err return err
} }
resp, err := a.HTTPClient.Do(req.WithContext(ctx)) req := req.WithContent(ctx)
resp, err := a.HTTPClient.Do(req)
if resp != nil { if resp != nil {
defer func() { defer func() {
err = resp.Body.Close() err = resp.Body.Close()