fix: async init aria2 to optimize start duration

pull/2582/head
Noah Hsu 2022-12-04 00:00:40 +08:00
parent 4c5285e094
commit 4e1be9bee6
1 changed files with 7 additions and 5 deletions

View File

@ -6,9 +6,11 @@ import (
) )
func InitAria2() { func InitAria2() {
_, err := aria2.InitClient(2) go func() {
if err != nil { _, err := aria2.InitClient(2)
//utils.Log.Errorf("failed to init aria2 client: %+v", err) if err != nil {
utils.Log.Infof("Aria2 not ready.") //utils.Log.Errorf("failed to init aria2 client: %+v", err)
} utils.Log.Infof("Aria2 not ready.")
}
}()
} }