summaryrefslogtreecommitdiff
path: root/sphinx/ext/apidoc.py
diff options
context:
space:
mode:
Diffstat (limited to 'sphinx/ext/apidoc.py')
-rw-r--r--sphinx/ext/apidoc.py6
1 files changed, 1 insertions, 5 deletions
diff --git a/sphinx/ext/apidoc.py b/sphinx/ext/apidoc.py
index c9367b465..2e5079681 100644
--- a/sphinx/ext/apidoc.py
+++ b/sphinx/ext/apidoc.py
@@ -179,11 +179,7 @@ def is_skipped_package(dirname: str, opts: Any, excludes: list[str] = []) -> boo
return True
# Check there is some showable module inside package
- if all(is_excluded(path.join(dirname, f), excludes) for f in files):
- # all submodules are excluded
- return True
- else:
- return False
+ return all(is_excluded(path.join(dirname, f), excludes) for f in files)
def is_skipped_module(filename: str, opts: Any, excludes: list[str]) -> bool: