Resolve linter issues
This commit is contained in:
@@ -1,17 +0,0 @@
|
|||||||
package dav
|
|
||||||
|
|
||||||
import (
|
|
||||||
"strings"
|
|
||||||
)
|
|
||||||
|
|
||||||
func splitIntoSegments(path string) []string {
|
|
||||||
segments := strings.Split(path, "/")
|
|
||||||
// remove empty segments
|
|
||||||
for i := 0; i < len(segments); i++ {
|
|
||||||
if segments[i] == "" {
|
|
||||||
segments = append(segments[:i], segments[i+1:]...)
|
|
||||||
i--
|
|
||||||
}
|
|
||||||
}
|
|
||||||
return segments
|
|
||||||
}
|
|
||||||
@@ -1,11 +0,0 @@
|
|||||||
package http
|
|
||||||
|
|
||||||
func removeEmptySegments(urlSegments []string) []string {
|
|
||||||
var result []string
|
|
||||||
for _, s := range urlSegments {
|
|
||||||
if s != "" {
|
|
||||||
result = append(result, s)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
return result
|
|
||||||
}
|
|
||||||
@@ -173,7 +173,6 @@ func (t *TorrentManager) getMoreInfo(rdTorrent realdebrid.Torrent) *Torrent {
|
|||||||
// all links are still intact! good!
|
// all links are still intact! good!
|
||||||
for i, file := range selectedFiles {
|
for i, file := range selectedFiles {
|
||||||
file.Link = info.Links[i]
|
file.Link = info.Links[i]
|
||||||
i++
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
torrent.SelectedFiles = cmap.New[*File]()
|
torrent.SelectedFiles = cmap.New[*File]()
|
||||||
|
|||||||
Reference in New Issue
Block a user