fix(download-clients): qbittorrent type ratelimit conversion error (#301)

This commit is contained in:
Kyle Sanderson 2022-06-11 11:33:42 -07:00 committed by GitHub
parent 058a220467
commit 2ab7133dd0
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) * 1000)
options["upLimit"] = strconv.FormatInt(action.LimitUploadSpeed * 1000, 10)
}
if action.LimitDownloadSpeed > 0 {
options["dlLimit"] = (strconv.FormatInt(action.LimitDownloadSpeed, 10) * 1000)
options["dlLimit"] = strconv.FormatInt(action.LimitDownloadSpeed * 1000, 10)
}
if action.LimitRatio > 0 {
options["ratioLimit"] = strconv.FormatFloat(action.LimitRatio, 'r', 2, 64)