Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/MHSanaei/3x-ui.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/web/job
diff options
context:
space:
mode:
Diffstat (limited to 'web/job')
-rw-r--r--web/job/check_inbound_job.go6
1 files changed, 4 insertions, 2 deletions
diff --git a/web/job/check_inbound_job.go b/web/job/check_inbound_job.go
index cb8bd331..2044ce68 100644
--- a/web/job/check_inbound_job.go
+++ b/web/job/check_inbound_job.go
@@ -25,11 +25,13 @@ func (j *CheckInboundJob) Run() {
}
}
- count, err = j.inboundService.DisableInvalidInbounds()
+ needRestart, count, err = j.inboundService.DisableInvalidInbounds()
if err != nil {
logger.Warning("Error in disabling invalid inbounds:", err)
} else if count > 0 {
logger.Debugf("%v inbounds disabled", count)
- j.xrayService.SetToNeedRestart()
+ if needRestart {
+ j.xrayService.SetToNeedRestart()
+ }
}
}