From 7bf0ef40fa7f6323f57f057f2ecdc6f1b3dafdb4 Mon Sep 17 00:00:00 2001 From: weibaohui Date: Fri, 18 Oct 2024 16:08:49 +0800 Subject: [PATCH] =?UTF-8?q?=E7=A7=BB=E9=99=A4=E8=8E=B7=E5=8F=96=E6=96=87?= =?UTF-8?q?=E4=BB=B6=E5=88=97=E8=A1=A8=E9=94=99=E8=AF=AF=E6=B6=88=E6=81=AF?= =?UTF-8?q?=E4=B8=AD=E7=9A=84=E5=86=97=E4=BD=99=E4=BF=A1=E6=81=AF?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 在Pod控制器的pod_file.go中,精简了获取文件列表失败时的错误消息。删除了错误信息中不必要的详细解释,使错误消息更加简洁明了。 --- pkg/controller/pod/pod_file.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pkg/controller/pod/pod_file.go b/pkg/controller/pod/pod_file.go index 45fcf1d..e148613 100644 --- a/pkg/controller/pod/pod_file.go +++ b/pkg/controller/pod/pod_file.go @@ -45,7 +45,7 @@ func FileListHandler(c *gin.Context) { // 获取文件列表 nodes, err := pf.GetFileList(info.Path) if err != nil { - amis.WriteJsonError(c, fmt.Errorf("获取文件列表失败,容器内没有shell或者没有ls命令:%v", err)) + amis.WriteJsonError(c, fmt.Errorf("获取文件列表失败,容器内没有shell或者没有ls命令")) return } amis.WriteJsonList(c, nodes)