mirror of
https://github.com/juanfont/headscale.git
synced 2024-12-03 04:03:05 +00:00
Fix rebased errors scope in machine.go
Signed-off-by: Laurent Marchaud <laurent@marchaud.com>
This commit is contained in:
parent
a31432ee7b
commit
fca33aacbe
1 changed files with 4 additions and 4 deletions
|
@ -24,9 +24,9 @@ const (
|
||||||
ErrMachineNotFoundRegistrationCache = Error(
|
ErrMachineNotFoundRegistrationCache = Error(
|
||||||
"machine not found in registration cache",
|
"machine not found in registration cache",
|
||||||
)
|
)
|
||||||
errCouldNotConvertMachineInterface = Error("failed to convert machine interface")
|
ErrCouldNotConvertMachineInterface = Error("failed to convert machine interface")
|
||||||
errHostnameTooLong = Error("Hostname too long")
|
ErrHostnameTooLong = Error("Hostname too long")
|
||||||
errDifferentRegisteredNamespace = Error("machine was previously registered with a different namespace")
|
ErrDifferentRegisteredNamespace = Error("machine was previously registered with a different namespace")
|
||||||
MachineGivenNameHashLength = 8
|
MachineGivenNameHashLength = 8
|
||||||
MachineGivenNameTrimSize = 2
|
MachineGivenNameTrimSize = 2
|
||||||
)
|
)
|
||||||
|
@ -792,7 +792,7 @@ func (h *Headscale) RegisterMachineFromAuthCallback(
|
||||||
|
|
||||||
// Registration of expired machine with different namespace
|
// Registration of expired machine with different namespace
|
||||||
if registrationMachine.ID != 0 && registrationMachine.NamespaceID != namespace.ID {
|
if registrationMachine.ID != 0 && registrationMachine.NamespaceID != namespace.ID {
|
||||||
return nil, errDifferentRegisteredNamespace
|
return nil, ErrDifferentRegisteredNamespace
|
||||||
}
|
}
|
||||||
|
|
||||||
registrationMachine.NamespaceID = namespace.ID
|
registrationMachine.NamespaceID = namespace.ID
|
||||||
|
|
Loading…
Reference in a new issue