fix: 网元主机telnet命令输入符判断
This commit is contained in:
@@ -203,7 +203,7 @@ func (s *NeHostController) Test(c *gin.Context) {
|
|||||||
return
|
return
|
||||||
}
|
}
|
||||||
defer client.Close()
|
defer client.Close()
|
||||||
if strings.HasSuffix(client.LastResult, "> ") || strings.HasSuffix(client.LastResult, "# ") {
|
if strings.HasSuffix(client.LastResult, ">") || strings.HasSuffix(client.LastResult, "> ") || strings.HasSuffix(client.LastResult, "# ") {
|
||||||
c.JSON(200, result.Ok(nil))
|
c.JSON(200, result.Ok(nil))
|
||||||
} else {
|
} else {
|
||||||
// 连接主机失败,请检查连接参数后重试
|
// 连接主机失败,请检查连接参数后重试
|
||||||
|
|||||||
Reference in New Issue
Block a user