修复ssh私钥登录时密码不能设置为空的问题
This commit is contained in:
1 parent
951feb65e0
commit
26e88ded8a
2 files changed
+11
-9
No files matched your search
@@ -60,6 +60,12 @@ func AssetUpdateEndpoint(c echo.Context) error {
|
||||
case "private-key":
|
||||
item.Password = "-"
|
||||
item.CredentialId = "-"
|
||||
if len(item.Username) == 0 {
|
||||
item.Username = "-"
|
||||
}
|
||||
if len(item.Passphrase) == 0 {
|
||||
item.Passphrase = "-"
|
||||
}
|
||||
case "custom":
|
||||
item.PrivateKey = "-"
|
||||
item.Passphrase = "-"
|
||||
|
||||
Reference in new issue
Block a user