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
diff options
context:
space:
mode:
Diffstat (limited to 'web/web.go')
-rw-r--r--web/web.go18
1 files changed, 0 insertions, 18 deletions
diff --git a/web/web.go b/web/web.go
index 81868d36..835e82e1 100644
--- a/web/web.go
+++ b/web/web.go
@@ -12,7 +12,6 @@ import (
"net"
"net/http"
"os"
- "path/filepath"
"strconv"
"strings"
"time"
@@ -295,26 +294,9 @@ func (s *Server) initRouter() (*gin.Engine, error) {
return engine, nil
}
-// normalizeExistingGeositeFiles normalizes country codes in all geosite .dat
-// files found in the bin directory so Xray-core can locate entries correctly.
-func normalizeExistingGeositeFiles() {
- binDir := config.GetBinFolderPath()
- matches, err := filepath.Glob(filepath.Join(binDir, "geosite*.dat"))
- if err != nil {
- logger.Warningf("Failed to glob geosite files: %v", err)
- return
- }
- for _, path := range matches {
- if err := service.NormalizeGeositeCountryCodes(path); err != nil {
- logger.Warningf("Failed to normalize geosite country codes in %s: %v", path, err)
- }
- }
-}
-
// startTask schedules background jobs (Xray checks, traffic jobs, cron
// jobs) which the panel relies on for periodic maintenance and monitoring.
func (s *Server) startTask() {
- normalizeExistingGeositeFiles()
s.customGeoService.EnsureOnStartup()
err := s.xrayService.RestartXray(true)
if err != nil {