mirror of
https://github.com/XTLS/Xray-core.git
synced 2025-04-30 09:18:34 +00:00
Run "go fmt ./..."
This commit is contained in:
parent
667279af57
commit
ee21763928
9 changed files with 17 additions and 17 deletions
|
@ -17,7 +17,7 @@ func Authenticate(b []byte) uint32 {
|
|||
return fnv1hash.Sum32()
|
||||
}
|
||||
|
||||
// [DEPRECATED 2023-06]
|
||||
// [DEPRECATED 2023-06]
|
||||
type NoOpAuthenticator struct{}
|
||||
|
||||
func (NoOpAuthenticator) NonceSize() int {
|
||||
|
|
|
@ -30,14 +30,14 @@ import (
|
|||
|
||||
type userByEmail struct {
|
||||
sync.Mutex
|
||||
cache map[string]*protocol.MemoryUser
|
||||
defaultLevel uint32
|
||||
cache map[string]*protocol.MemoryUser
|
||||
defaultLevel uint32
|
||||
}
|
||||
|
||||
func newUserByEmail(config *DefaultConfig) *userByEmail {
|
||||
return &userByEmail{
|
||||
cache: make(map[string]*protocol.MemoryUser),
|
||||
defaultLevel: config.Level,
|
||||
cache: make(map[string]*protocol.MemoryUser),
|
||||
defaultLevel: config.Level,
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -68,7 +68,7 @@ func (v *userByEmail) Get(email string) (*protocol.MemoryUser, bool) {
|
|||
if !found {
|
||||
id := uuid.New()
|
||||
rawAccount := &vmess.Account{
|
||||
Id: id.String(),
|
||||
Id: id.String(),
|
||||
}
|
||||
account, err := rawAccount.AsAccount()
|
||||
common.Must(err)
|
||||
|
|
|
@ -11,7 +11,7 @@ import (
|
|||
|
||||
func (h *Handler) handleSwitchAccount(cmd *protocol.CommandSwitchAccount) {
|
||||
rawAccount := &vmess.Account{
|
||||
Id: cmd.ID.String(),
|
||||
Id: cmd.ID.String(),
|
||||
SecuritySettings: &protocol.SecurityConfig{
|
||||
Type: protocol.SecurityType_AUTO,
|
||||
},
|
||||
|
|
|
@ -15,7 +15,7 @@ import (
|
|||
// TimedUserValidator is a user Validator based on time.
|
||||
type TimedUserValidator struct {
|
||||
sync.RWMutex
|
||||
users []*protocol.MemoryUser
|
||||
users []*protocol.MemoryUser
|
||||
|
||||
behaviorSeed uint64
|
||||
behaviorFused bool
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue