mirror of
https://github.com/simon-ding/polaris.git
synced 2026-02-06 23:21:00 +08:00
update stun proxy
This commit is contained in:
@@ -12,11 +12,20 @@ import (
|
||||
)
|
||||
|
||||
func (s *Engine) stunProxyDownloadClient() error {
|
||||
|
||||
return s.StartStunProxy("")
|
||||
}
|
||||
|
||||
|
||||
func (s *Engine) StartStunProxy(name string) error {
|
||||
downloaders := s.db.GetAllDonloadClients()
|
||||
for _, d := range downloaders {
|
||||
if !d.Enable {
|
||||
continue
|
||||
}
|
||||
if name != "" && d.Name != name {
|
||||
continue
|
||||
}
|
||||
|
||||
if d.Implementation != downloadclients.ImplementationQbittorrent { //TODO only support qbittorrent for now
|
||||
continue
|
||||
@@ -41,4 +50,4 @@ func (s *Engine) stunProxyDownloadClient() error {
|
||||
|
||||
}
|
||||
return nil
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user