fix(download-clients): qBit transform speed limit from B to KB (#300)

This commit is contained in:
Kyle Sanderson 2022-06-11 11:18:17 -07:00 committed by GitHub
parent 4677057bee
commit 058a220467
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -56,10 +56,10 @@ func (s *service) qbittorrent(qbt *qbittorrent.Client, action domain.Action, rel
options["tags"] = tagsArgs
}
if action.LimitUploadSpeed > 0 {
options["upLimit"] = strconv.FormatInt(action.LimitUploadSpeed, 10)
options["upLimit"] = (strconv.FormatInt(action.LimitUploadSpeed, 10) * 1000)
}
if action.LimitDownloadSpeed > 0 {
options["dlLimit"] = strconv.FormatInt(action.LimitDownloadSpeed, 10)
options["dlLimit"] = (strconv.FormatInt(action.LimitDownloadSpeed, 10) * 1000)
}
if action.LimitRatio > 0 {
options["ratioLimit"] = strconv.FormatFloat(action.LimitRatio, 'r', 2, 64)