From 13679ff301335d69ce82fd8244e60ad1b88d951c Mon Sep 17 00:00:00 2001 From: Ikko Eltociear Ashimine Date: Mon, 20 Mar 2023 11:41:54 +0900 Subject: [PATCH] Fix typo in image.go (#306) lenth -> length --- backend/app/service/image.go | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/backend/app/service/image.go b/backend/app/service/image.go index 2618beeb4..dcc344daf 100644 --- a/backend/app/service/image.go +++ b/backend/app/service/image.go @@ -54,8 +54,8 @@ func (u *ImageService) Page(req dto.SearchWithPage) (int64, interface{}, error) return 0, nil, err } if len(req.Info) != 0 { - lenth, count := len(list), 0 - for count < lenth { + length, count := len(list), 0 + for count < length { hasTag := false for _, tag := range list[count].RepoTags { if strings.Contains(tag, req.Info) { @@ -65,7 +65,7 @@ func (u *ImageService) Page(req dto.SearchWithPage) (int64, interface{}, error) } if !hasTag { list = append(list[:count], list[(count+1):]...) - lenth-- + length-- } else { count++ }