avoid reset in QueryStatsRequest (#4202)

This commit is contained in:
Amirmohammad Sadat Shokouhi
2026-05-10 12:29:42 +03:30
committed by GitHub
parent 7cd26a0583
commit 14165fc54d
2 changed files with 17 additions and 5 deletions
+2 -1
View File
@@ -212,7 +212,7 @@ func (s *XrayService) GetXrayTraffic() ([]*xray.Traffic, []*xray.ClientTraffic,
}
defer s.xrayAPI.Close()
traffic, clientTraffic, err := s.xrayAPI.GetTraffic(true)
traffic, clientTraffic, err := s.xrayAPI.GetTraffic()
if err != nil {
logger.Debug("Failed to fetch Xray traffic:", err)
return nil, nil, err
@@ -242,6 +242,7 @@ func (s *XrayService) RestartXray(isForce bool) error {
p = xray.NewProcess(xrayConfig)
result = ""
s.xrayAPI.StatsLastValues = nil
err = p.Start()
if err != nil {
return err