mirror of
https://github.com/librespeed/speedtest
synced 2026-11-26 09:58:03 +08:00
Return empty rawIspInfo when no ISP info is obtained
This commit is contained in:
1 parent
79b4c54770
commit
73318e153b
1 file changed
+3
@@ -179,6 +179,9 @@ func getIP(w http.ResponseWriter, r *http.Request) {
|
||||
}
|
||||
|
||||
ret.ProcessedString += " - " + isp
|
||||
} else {
|
||||
// return an empty JSON object to avoid parse errors
|
||||
ret.RawISPInfo = "{}"
|
||||
}
|
||||
|
||||
render.JSON(w, r, ret)
|
||||
|
||||
Reference in new issue
Block a user