Chore: Run gofmt (#3990)

This commit is contained in:
zonescape 2024-11-09 14:16:11 +03:00 committed by GitHub
parent bc4bf3d38f
commit 83bab5dd90
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
50 changed files with 272 additions and 273 deletions

View file

@ -13,7 +13,7 @@ type DNSOutboundConfig struct {
Port uint16 `json:"port"`
UserLevel uint32 `json:"userLevel"`
NonIPQuery string `json:"nonIPQuery"`
BlockTypes []int32 `json:"blockTypes"`
BlockTypes []int32 `json:"blockTypes"`
}
func (c *DNSOutboundConfig) Build() (proto.Message, error) {

View file

@ -6,11 +6,11 @@ import (
)
type DokodemoConfig struct {
Host *Address `json:"address"`
PortValue uint16 `json:"port"`
NetworkList *NetworkList `json:"network"`
Redirect bool `json:"followRedirect"`
UserLevel uint32 `json:"userLevel"`
Host *Address `json:"address"`
PortValue uint16 `json:"port"`
NetworkList *NetworkList `json:"network"`
Redirect bool `json:"followRedirect"`
UserLevel uint32 `json:"userLevel"`
}
func (v *DokodemoConfig) Build() (proto.Message, error) {

View file

@ -2,7 +2,7 @@ package conf
import (
"google.golang.org/protobuf/proto"
"github.com/xtls/xray-core/app/observatory"
"github.com/xtls/xray-core/app/observatory/burst"
"github.com/xtls/xray-core/infra/conf/cfgcommon/duration"

View file

@ -71,9 +71,9 @@ func (r *BalancingRule) Build() (*router.BalancingRule, error) {
}
type RouterConfig struct {
RuleList []json.RawMessage `json:"rules"`
DomainStrategy *string `json:"domainStrategy"`
Balancers []*BalancingRule `json:"balancers"`
RuleList []json.RawMessage `json:"rules"`
DomainStrategy *string `json:"domainStrategy"`
Balancers []*BalancingRule `json:"balancers"`
DomainMatcher string `json:"domainMatcher"`
}

View file

@ -2,9 +2,9 @@ package conf
import (
"google.golang.org/protobuf/proto"
"github.com/xtls/xray-core/app/router"
"github.com/xtls/xray-core/app/observatory/burst"
"github.com/xtls/xray-core/app/router"
"github.com/xtls/xray-core/infra/conf/cfgcommon/duration"
)
@ -46,10 +46,10 @@ type strategyLeastLoadConfig struct {
// healthCheckSettings holds settings for health Checker
type healthCheckSettings struct {
Destination string `json:"destination"`
Connectivity string `json:"connectivity"`
Destination string `json:"destination"`
Connectivity string `json:"connectivity"`
Interval duration.Duration `json:"interval"`
SamplingCount int `json:"sampling"`
SamplingCount int `json:"sampling"`
Timeout duration.Duration `json:"timeout"`
}

View file

@ -363,7 +363,7 @@ func (c *StatsConfig) Build() (*stats.Config, error) {
type Config struct {
// Deprecated: Global transport config is no longer used
// left for returning error
Transport map[string]json.RawMessage `json:"transport"`
Transport map[string]json.RawMessage `json:"transport"`
LogConfig *LogConfig `json:"log"`
RouterConfig *RouterConfig `json:"routing"`