From b9f8b8ec1cc59fcf4838fee40a317f8225b3e794 Mon Sep 17 00:00:00 2001 From: Ali Erdem Cerrah <37017703+acerrah@users.noreply.github.com> Date: Fri, 4 Sep 2026 16:41:38 +0300 Subject: [PATCH] fix: include common prefixes in ListObjectsV2 key count --- backend/posix/posix.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/backend/posix/posix.go b/backend/posix/posix.go index 78abc847..cc96662c 100644 --- a/backend/posix/posix.go +++ b/backend/posix/posix.go @@ -6268,7 +6268,7 @@ func (p *Posix) ListObjectsV2Parametrized(ctx context.Context, input *s3.ListObj return s3response.ListObjectsV2Result{}, fmt.Errorf("walk %v: %w", bucket, err) } - count := int32(len(results.Objects)) + count := int32(len(results.Objects) + len(results.CommonPrefixes)) return s3response.ListObjectsV2Result{ CommonPrefixes: results.CommonPrefixes,