From b9310154a77dabe8ba9d63cd1888281b4bd4294b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E4=B8=96=E7=95=8C?= Date: Sun, 3 Sep 2023 21:13:16 +0800 Subject: [PATCH] clash-api: Move default mode to first --- experimental/clashapi/server.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/experimental/clashapi/server.go b/experimental/clashapi/server.go index f9dacb5d..9ac06620 100644 --- a/experimental/clashapi/server.go +++ b/experimental/clashapi/server.go @@ -90,7 +90,7 @@ func NewServer(ctx context.Context, router adapter.Router, logFactory log.Observ defaultMode = options.DefaultMode } if !common.Contains(server.modeList, defaultMode) { - server.modeList = append(server.modeList, defaultMode) + server.modeList = append([]string{defaultMode}, server.modeList...) } server.mode = defaultMode if options.StoreMode || options.StoreSelected || options.StoreFakeIP || options.ExternalController == "" {