From: Ansab Gillani <56605828+ansabgillani@users.noreply.github.com> Date: Fri, 26 Aug 2022 21:21:40 +0000 (+0500) Subject: Fix documentation typo for pathlib.Path.walk (GH-96301) X-Git-Tag: v3.12.0a1~553 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=b462f143ff9592179d82680d0156eedb74705ed4;p=thirdparty%2FPython%2Fcpython.git Fix documentation typo for pathlib.Path.walk (GH-96301) --- diff --git a/Doc/library/pathlib.rst b/Doc/library/pathlib.rst index f7d7745eef52..1375ce1aef95 100644 --- a/Doc/library/pathlib.rst +++ b/Doc/library/pathlib.rst @@ -1038,7 +1038,7 @@ call fails (for example because the path doesn't exist). # Delete everything reachable from the directory "top". # CAUTION: This is dangerous! For example, if top == Path('/'), # it could delete all of your files. - for root, dirs, files in top.walk(topdown=False): + for root, dirs, files in top.walk(top_down=False): for name in files: (root / name).unlink() for name in dirs: