mirror of
https://github.com/XIU2/CloudflareSpeedTest.git
synced 2026-03-06 22:59:33 +08:00
修复 没有设置下载速度下限条件时输出测速结果数量异常的问题
This commit is contained in:
@@ -89,7 +89,9 @@ func TestDownloadSpeed(ipSet utils.PingDelaySet) (speedSet utils.DownloadSpeedSe
|
||||
}
|
||||
}
|
||||
bar.Done()
|
||||
if utils.Debug && len(speedSet) == 0 { // 调试模式下,没有满足速度限制的数据,返回所有测速数据供用户查看当前的测速结果,以便适当调低预期测速条件
|
||||
if MinSpeed == 0.00 { // 如果没有设置下载速度下限,则直接返回所有测速数据
|
||||
speedSet = utils.DownloadSpeedSet(ipSet)
|
||||
} else if utils.Debug && len(speedSet) == 0 { // 如果设置了下载速度下限,且是调试模式下,且没有找到任何一个满足条件的 IP 时,返回所有测速数据,供用户查看当前的测速结果,以便适当调低预期测速条件
|
||||
fmt.Println("\033[33m[调试] 没有满足 下载速度下限 条件的 IP,忽略条件返回所有测速数据(方便下次测速时调整条件)。\033[0m")
|
||||
speedSet = utils.DownloadSpeedSet(ipSet)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user