fix: panic when torrent not exist

This commit is contained in:
Simon Ding
2024-09-21 21:47:26 +08:00
parent 37dfb0fe94
commit 40c6e2df5c
5 changed files with 98 additions and 48 deletions

View File

@@ -1,14 +1,14 @@
package pkg
type Torrent interface {
Name() string
Progress() int
Name() (string, error)
Progress() (int, error)
Stop() error
Start() error
Remove() error
Save() string
Exists() bool
SeedRatio() *float64
SeedRatio() (float64, error)
}