removed unused code

This commit is contained in:
milarin 2023-01-30 21:28:25 +01:00
parent 8129c04ec5
commit 821163b1ef
2 changed files with 1 additions and 12 deletions

View File

@ -15,7 +15,7 @@ import (
var torrentLinkRegex = regexp.MustCompile(`https:\/\/nyaa\.si\/download\/(\d+?)\.torrent`)
func GetTorrents() ([]model.Torrent, error) {
resp, err := http.Get("https://nyaa.si/?page=rss")
resp, err := http.Get("https://nyaa.si/?page=rss&f=0&c=1_0")
if err != nil {
return nil, ErrTorrentNotObtainable.Wrap(err, "torrent data acqusition failed")
}

View File

@ -9,17 +9,6 @@ import (
"git.milar.in/nyaanime/model"
)
func AnimeEpExistsLocally(animeEp model.AnimeEpisode) bool {
animeEpPath := logic.GetAnimeEpFilepath(animeEp, "*")
files, err := filepath.Glob(animeEpPath)
if err != nil {
panic(err)
}
return len(files) > 0
}
func IsCurrentlyDownloading(animeEp model.AnimeEpisode) bool {
animeEpPath := logic.GetAnimeEpFilepath(animeEp, "lock")
_, err := os.Stat(animeEpPath)