Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit f87c9e6

Browse filesBrowse files
committed
minor #18499 [Finder] [Finder docs] Add early directory prunning filter support (mvorisek)
This PR was merged into the 6.4 branch. Discussion ---------- [Finder] [Finder docs] Add early directory prunning filter support Refs * symfony/symfony#50877 Commits ------- 4b08ee6 [Finder docs] Add early directory prunning filter support
2 parents 3197890 + 4b08ee6 commit f87c9e6
Copy full SHA for f87c9e6

File tree

1 file changed

+6
-0
lines changed
Filter options

1 file changed

+6
-0
lines changed

‎components/finder.rst

Copy file name to clipboardExpand all lines: components/finder.rst
+6Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -329,6 +329,12 @@ it is called with the file as a :class:`Symfony\\Component\\Finder\\SplFileInfo`
329329
instance. The file is excluded from the result set if the Closure returns
330330
``false``.
331331

332+
.. versionadded:: 6.4
333+
334+
Since Symfony 6.4, a filter can prune directories early, pass ``true`` as the second
335+
parameter for the ``filter()`` method and when the Closure returns ``false`` the deeper
336+
levels will not be traversed.
337+
332338
Sorting Results
333339
---------------
334340

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.