mirror of
https://github.com/juanfont/headscale.git
synced 2026-04-01 06:53:23 +02:00
Add and fix gosec
This commit is contained in:
@@ -95,8 +95,8 @@ func (h *Headscale) GetPreAuthKey(namespace string, key string) (*PreAuthKey, er
|
||||
|
||||
// DestroyPreAuthKey destroys a preauthkey. Returns error if the PreAuthKey
|
||||
// does not exist.
|
||||
func (h *Headscale) DestroyPreAuthKey(pak *PreAuthKey) error {
|
||||
if result := h.db.Unscoped().Delete(&pak); result.Error != nil {
|
||||
func (h *Headscale) DestroyPreAuthKey(pak PreAuthKey) error {
|
||||
if result := h.db.Unscoped().Delete(pak); result.Error != nil {
|
||||
return result.Error
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user