Remove unnecessary configs
This commit is contained in:
@@ -14,13 +14,11 @@ type ConfigInterface interface {
|
||||
MeetsConditions(directory, torrentName string, torrentIDs, fileNames []string) bool
|
||||
GetOnLibraryUpdate() string
|
||||
GetNetworkBufferSize() int
|
||||
GetMountPoint() string
|
||||
EnableRetainFolderNameExtension() bool
|
||||
EnableRetainRDTorrentName() bool
|
||||
GetRandomPreferredHost() string
|
||||
ShouldServeFromRclone() bool
|
||||
ShouldForceIPv6() bool
|
||||
GetRateLimitSleepSeconds() int
|
||||
GetRealDebridTimeout() int
|
||||
GetRetriesUntilFailed() int
|
||||
EnableDownloadCache() bool
|
||||
@@ -32,12 +30,10 @@ type ZurgConfig struct {
|
||||
Host string `yaml:"host"`
|
||||
Port string `yaml:"port"`
|
||||
NumOfWorkers int `yaml:"concurrent_workers"`
|
||||
RateLimitSleepSeconds int `yaml:"rate_limit_sleep_secs"`
|
||||
RefreshEverySeconds int `yaml:"check_for_changes_every_secs"`
|
||||
CanRepair bool `yaml:"enable_repair"`
|
||||
OnLibraryUpdate string `yaml:"on_library_update"`
|
||||
NetworkBufferSize int `yaml:"network_buffer_size"`
|
||||
MountPoint string `yaml:"mount_point"`
|
||||
RetainFolderNameExtension bool `yaml:"retain_folder_name_extension"`
|
||||
RetainRDTorrentName bool `yaml:"retain_rd_torrent_name"`
|
||||
PreferredHosts []string `yaml:"preferred_hosts"`
|
||||
@@ -95,13 +91,6 @@ func (z *ZurgConfig) GetNetworkBufferSize() int {
|
||||
return z.NetworkBufferSize
|
||||
}
|
||||
|
||||
func (z *ZurgConfig) GetMountPoint() string {
|
||||
if z.MountPoint == "" {
|
||||
return "/app/mnt"
|
||||
}
|
||||
return z.MountPoint
|
||||
}
|
||||
|
||||
func (z *ZurgConfig) EnableRetainFolderNameExtension() bool {
|
||||
return z.RetainFolderNameExtension
|
||||
}
|
||||
@@ -126,20 +115,6 @@ func (z *ZurgConfig) ShouldForceIPv6() bool {
|
||||
return z.ForceIPv6
|
||||
}
|
||||
|
||||
func (z *ZurgConfig) GetRateLimitSleepSeconds() int {
|
||||
if z.RateLimitSleepSeconds == 0 {
|
||||
return 4
|
||||
}
|
||||
return z.RateLimitSleepSeconds
|
||||
}
|
||||
|
||||
func (z *ZurgConfig) GetRealDebridTimeout() int {
|
||||
if z.RealDebridTimeout == 0 {
|
||||
return 60
|
||||
}
|
||||
return z.RealDebridTimeout
|
||||
}
|
||||
|
||||
func (z *ZurgConfig) GetRetriesUntilFailed() int {
|
||||
if z.RetriesUntilFailed == 0 {
|
||||
return 5
|
||||
@@ -150,3 +125,10 @@ func (z *ZurgConfig) GetRetriesUntilFailed() int {
|
||||
func (z *ZurgConfig) EnableDownloadCache() bool {
|
||||
return z.UseDownloadCache
|
||||
}
|
||||
|
||||
func (z *ZurgConfig) GetRealDebridTimeout() int {
|
||||
if z.RealDebridTimeout == 0 {
|
||||
return 60
|
||||
}
|
||||
return z.RealDebridTimeout
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user