mirror of
https://github.com/shtorm-7/sing-box-extended.git
synced 2026-06-08 20:24:56 +03:00
Add http/block outbound & Improve route
This commit is contained in:
@@ -14,7 +14,7 @@ func New(router adapter.Router, options option.DialerOptions) N.Dialer {
|
||||
} else {
|
||||
dialer = newDetour(router, options)
|
||||
}
|
||||
if options.OverrideOptions != nil {
|
||||
if options.OverrideOptions.IsValid() {
|
||||
dialer = newOverride(dialer, common.PtrValueOrDefault(options.OverrideOptions))
|
||||
}
|
||||
return dialer
|
||||
|
||||
@@ -22,9 +22,6 @@ type overrideDialer struct {
|
||||
}
|
||||
|
||||
func newOverride(upstream N.Dialer, options option.OverrideStreamOptions) N.Dialer {
|
||||
if !options.TLS && !options.UDPOverTCP {
|
||||
return upstream
|
||||
}
|
||||
return &overrideDialer{
|
||||
upstream,
|
||||
options.TLS,
|
||||
|
||||
Reference in New Issue
Block a user