diff options
| author | MHSanaei <ho3ein.sanaei@gmail.com> | 2023-07-18 02:10:22 +0300 |
|---|---|---|
| committer | MHSanaei <ho3ein.sanaei@gmail.com> | 2023-07-18 02:10:22 +0300 |
| commit | 1f78842b707a1190b6a84aded269d664254a7f1d (patch) | |
| tree | f9226bfda4856a6289a657cff21234738be4f8c3 /web/job | |
| parent | 81a057d63876df5ba69260ac6b97aeeb7964c87d (diff) | |
[feature] using xray API for inbound
Co-Authored-By: Alireza Ahmadi <alireza7@gmail.com>
Diffstat (limited to 'web/job')
| -rw-r--r-- | web/job/check_inbound_job.go | 6 |
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() + } } } |
