mirror of
https://github.com/alireza0/s-ui.git
synced 2026-08-27 04:17:00 +00:00
external sub connection timeout
This commit is contained in:
parent
51d63dd71c
commit
4915ad5cc6
1 changed files with 2 additions and 1 deletions
|
|
@ -6,6 +6,7 @@ import (
|
|||
"io"
|
||||
"net/http"
|
||||
"strings"
|
||||
"time"
|
||||
|
||||
"github.com/alireza0/s-ui/logger"
|
||||
"github.com/alireza0/s-ui/util/common"
|
||||
|
|
@ -16,7 +17,7 @@ func GetExternalLink(url string) string {
|
|||
TLSClientConfig: &tls.Config{InsecureSkipVerify: true},
|
||||
}
|
||||
|
||||
client := &http.Client{Transport: tr}
|
||||
client := &http.Client{Transport: tr, Timeout: 10 * time.Second}
|
||||
|
||||
response, err := client.Get(url)
|
||||
if err != nil {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue