turn-off unexpected debug logging in List() calls (#19903)

This commit is contained in:
Harshavardhana 2024-06-09 21:34:26 -07:00 committed by GitHub
parent f933b0b708
commit 6c7a21df6b
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 6 additions and 2 deletions

View File

@ -748,7 +748,9 @@ func mergeEntryChannels(ctx context.Context, in []chan metaCacheEntry, out chan<
if !dirMatches {
// We have an object `name` or 'name/' and a directory `name/`.
if other.isDir() {
console.Debugln("mergeEntryChannels: discarding directory", other.name, "for object", best.name)
if serverDebugLog {
console.Debugln("mergeEntryChannels: discarding directory", other.name, "for object", best.name)
}
// Discard the directory.
if err := selectFrom(otherIdx); err != nil {
return err
@ -756,7 +758,9 @@ func mergeEntryChannels(ctx context.Context, in []chan metaCacheEntry, out chan<
continue
}
// Replace directory with object.
console.Debugln("mergeEntryChannels: discarding directory", best.name, "for object", other.name)
if serverDebugLog {
console.Debugln("mergeEntryChannels: discarding directory", best.name, "for object", other.name)
}
toMerge = toMerge[:0]
best = other
bestIdx = otherIdx