[wp-trac] [WordPress Trac] #55806: `get_pages` should use `WP_Query` internally

WordPress Trac noreply at wordpress.org
Tue May 24 12:39:50 UTC 2022

#55806: `get_pages` should use `WP_Query` internally
 Reporter:  spacedmonkey  |      Owner:  (none)
     Type:  enhancement   |     Status:  new
 Priority:  normal        |  Milestone:  Awaiting Review
Component:  Query         |    Version:
 Severity:  normal        |   Keywords:
  Focuses:                |
 The function `get_pages` does raw database calls. It does not use the
 class WP_Query. This means that performance, bug fixes and filters are not
 applied to `get_pages`. To improve maintainability and reduce code,
 `get_pages` should be refactored to use  `WP_Query` internally.

Ticket URL: <https://core.trac.wordpress.org/ticket/55806>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform

More information about the wp-trac mailing list