Skip to content

Commit

Permalink
fix: invalid path
Browse files Browse the repository at this point in the history
  • Loading branch information
AlkaidChan committed Sep 10, 2024
1 parent baee26b commit b0157bc
Showing 1 changed file with 0 additions and 5 deletions.
5 changes: 0 additions & 5 deletions bcs-services/bcs-bscp/pkg/criteria/validator/file.go
Original file line number Diff line number Diff line change
Expand Up @@ -46,11 +46,6 @@ func ValidateUnixFilePath(kit *kit.Kit, path string) error {
"cannot contain consecutive '/'", path))
}

// 3. 检查是否以 '/' 结尾(除非是根路径)
if len(path) > 1 && strings.HasSuffix(path, "/") {
return errf.Errorf(errf.InvalidArgument, i18n.T(kit, "invalid path %s, the path cannot end with '/'", path))
}

return nil
}

Expand Down

0 comments on commit b0157bc

Please sign in to comment.