From 823ba67709f6391911f51adc315e9a275e371861 Mon Sep 17 00:00:00 2001 From: drfho Date: Mon, 14 Aug 2023 13:40:57 +0200 Subject: [PATCH] meaningful var name 'c'-> 'count' --- src/Products/CMFCore/DirectoryView.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/Products/CMFCore/DirectoryView.py b/src/Products/CMFCore/DirectoryView.py index 9f8b3f9..092f81c 100644 --- a/src/Products/CMFCore/DirectoryView.py +++ b/src/Products/CMFCore/DirectoryView.py @@ -359,11 +359,11 @@ def listDirectories(self): registerMetaType = _dirreg.registerMetaType -def listFolderHierarchy(ob, path, rval, adding_meta_type=None, max=0, c=0): +def listFolderHierarchy(ob, path, rval, adding_meta_type=None, max=0, count=0): if not hasattr(ob, 'objectValues'): return for subob in ob.objectValues(): - c += 1 + count += 1 base = getattr(subob, 'aq_base', subob) if getattr(base, 'isPrincipiaFolderish', 0): @@ -390,10 +390,10 @@ def listFolderHierarchy(ob, path, rval, adding_meta_type=None, max=0, c=0): name = f'{subpath} ({title})' else: name = subpath - if max == 0 or c <= max: + if max == 0 or count <= max: rval.append((subpath, name)) listFolderHierarchy(subob, subpath, rval, adding_meta_type, - max, c) + max, count) @implementer(IDirectoryView)