1
0
mirror of https://github.com/v2fly/v2ray-core.git synced 2024-06-27 17:55:23 +00:00

Merge pull request #153 from Loyalsoldier/minor-fixes

Minor fixes
This commit is contained in:
Kslr 2020-09-02 16:29:26 +08:00 committed by GitHub
commit 971c5f2ee8
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 2 additions and 3 deletions

View File

@ -114,8 +114,7 @@ func New(ctx context.Context, config *Config) (*Server, error) {
log.Fatalln(newError("DNS config error").Base(err)) log.Fatalln(newError("DNS config error").Base(err))
} }
server.clients = append(server.clients, NewDoHLocalNameServer(u, server.clientIP)) server.clients = append(server.clients, NewDoHLocalNameServer(u, server.clientIP))
} else if address.Family().IsDomain() && } else if address.Family().IsDomain() && strings.HasPrefix(address.Domain(), "https://") {
strings.HasPrefix(address.Domain(), "https://") {
// DOH Remote mode // DOH Remote mode
u, err := url.Parse(address.Domain()) u, err := url.Parse(address.Domain())
if err != nil { if err != nil {

View File

@ -49,7 +49,7 @@ func (t Type) New(pattern string) (Matcher, error) {
// IndexMatcher is the interface for matching with a group of matchers. // IndexMatcher is the interface for matching with a group of matchers.
type IndexMatcher interface { type IndexMatcher interface {
// Match returns the the index of a matcher that matches the input. It returns empty array if no such matcher exists. // Match returns the index of a matcher that matches the input. It returns empty array if no such matcher exists.
Match(input string) []uint32 Match(input string) []uint32
} }