Darien Raymond il y a 9 ans
Parent
commit
2e1c2b95e0
1 fichiers modifiés avec 1 ajouts et 5 suppressions
  1. 1 5
      common/protocol/id.go

+ 1 - 5
common/protocol/id.go

@@ -5,7 +5,6 @@ import (
 	"crypto/md5"
 	"hash"
 
-	"v2ray.com/core/common/errors"
 	"v2ray.com/core/common/uuid"
 )
 
@@ -13,10 +12,6 @@ const (
 	IDBytesLen = 16
 )
 
-var (
-	InvalidID = errors.New("Invalid ID.")
-)
-
 type IDHash func(key []byte) hash.Hash
 
 func DefaultIDHash(key []byte) hash.Hash {
@@ -29,6 +24,7 @@ type ID struct {
 	cmdKey [IDBytesLen]byte
 }
 
+// Equals returns true if this ID equals to the other one.
 func (v *ID) Equals(another *ID) bool {
 	return v.uuid.Equals(another.uuid)
 }