Parcourir la source

Add debug log when SSH key for deletion isn't found

John Maguire il y a 9 ans
Parent
commit
caa4ca46c0
1 fichiers modifiés avec 5 ajouts et 0 suppressions
  1. 5 0
      models/ssh_key.go

+ 5 - 0
models/ssh_key.go

@@ -374,6 +374,11 @@ func rewriteAuthorizedKeys(key *PublicKey, p, tmpP string) error {
 			break
 		}
 	}
+
+	if !isFound {
+		log.Warn("SSH key %d not found in authorized_keys file for deletion", key.ID)
+	}
+
 	return nil
 }