add 增加延时设置
This commit is contained in:
parent
962f7c42bd
commit
b422b2c5c6
@ -15,6 +15,7 @@ Wskey: # 填空默认禁用wskey转换 需要的填true
|
||||
IsAddFriend: #填写true或者false false
|
||||
Lim: #填写1-N 代表限制次数
|
||||
Tyt: #填写1-N 代表推一推需要的互助值,默认为8
|
||||
Later: #延时防止黑IP自己设置 默认60 不怕黑的改为1即可 单位是秒
|
||||
theme:
|
||||
static: ./static
|
||||
master:
|
||||
|
||||
@ -123,7 +123,7 @@ func initCookie() {
|
||||
cks := GetJdCookies()
|
||||
//l := len(cks)
|
||||
for i := range cks {
|
||||
time.Sleep(time.Second * time.Duration(60))
|
||||
time.Sleep(time.Second * time.Duration(Config.Later))
|
||||
if cks[i].Available == True && !CookieOK(&cks[i]) {
|
||||
logs.Info("开始禁用")
|
||||
cks[i].OutPool()
|
||||
|
||||
@ -43,6 +43,7 @@ type Yaml struct {
|
||||
Lim int `yaml:"Lim"`
|
||||
Tyt int `yaml:"Tyt"`
|
||||
IFC bool `yaml:"IFC"`
|
||||
Later int `yaml:"Later"`
|
||||
Node string
|
||||
Npm string
|
||||
Python string
|
||||
@ -108,6 +109,9 @@ func initConfig() {
|
||||
if Config.Tyt == 0 {
|
||||
Config.Tyt = 8
|
||||
}
|
||||
if Config.Later == 0 {
|
||||
Config.Later = 60
|
||||
}
|
||||
if Config.Database == "" {
|
||||
Config.Database = ExecPath + "/.xdd.db"
|
||||
}
|
||||
|
||||
Loading…
Reference in New Issue
Block a user