- 增加到期时间限制 - 新增配置面板 https 访问后,http 自动跳转 https(同端口) - 降低获取系统连接数的 cpu 使用率 - 优化界面 - VMess 协议 alterId 默认改为 0 - 修复旧版本 iOS 系统白屏问题 - 修复重启面板后 xray 没有启动的问题
26 lines
518 B
Go
26 lines
518 B
Go
package job
|
|
|
|
import (
|
|
"x-ui/logger"
|
|
"x-ui/web/service"
|
|
)
|
|
|
|
type CheckInboundJob struct {
|
|
xrayService service.XrayService
|
|
inboundService service.InboundService
|
|
}
|
|
|
|
func NewCheckInboundJob() *CheckInboundJob {
|
|
return new(CheckInboundJob)
|
|
}
|
|
|
|
func (j *CheckInboundJob) Run() {
|
|
count, err := j.inboundService.DisableInvalidInbounds()
|
|
if err != nil {
|
|
logger.Warning("disable invalid inbounds err:", err)
|
|
} else if count > 0 {
|
|
logger.Debugf("disabled %v inbounds", count)
|
|
j.xrayService.SetToNeedRestart()
|
|
}
|
|
}
|