MCPcopy
hub / github.com/ChineseSubFinder/ChineseSubFinder / getPublicIP

Function getPublicIP

pkg/util.go:85–97  ·  view source on GitHub ↗
(inputSite string)

Source from the content-addressed store, hash-verified

83}
84
85func getPublicIP(inputSite string) string {
86
87 var client *resty.Client
88 client, err := NewHttpClient()
89 if err != nil {
90 return ""
91 }
92 response, err := client.R().Get(inputSite)
93 if err != nil {
94 return ""
95 }
96 return response.String()
97}
98
99func GetPublicIP(log *logrus.Logger, queue *settings.TaskQueue) string {
100

Callers 1

GetPublicIPFunction · 0.85

Calls 3

NewHttpClientFunction · 0.85
GetMethod · 0.65
StringMethod · 0.45

Tested by

no test coverage detected