[wp-trac] [WordPress Trac] #34047: Split up `wp_lazyload_term_meta()`; check `$check` before lazyloading

WordPress Trac noreply at wordpress.org
Mon Sep 28 20:31:43 UTC 2015


#34047: Split up `wp_lazyload_term_meta()`; check `$check` before lazyloading
-------------------------+--------------------
 Reporter:  dlh          |       Owner:
     Type:  enhancement  |      Status:  new
 Priority:  normal       |   Milestone:  4.4
Component:  Taxonomy     |     Version:  trunk
 Severity:  normal       |  Resolution:
 Keywords:               |     Focuses:
-------------------------+--------------------
Changes (by boonebgorges):

 * milestone:  Awaiting Review => 4.4


Comment:

 Yes, this is a good idea.

 My first instinct when writing this lazyloading was to make it a method of
 `WP_Query`. Then it's automatically portable to other `WP_Query`
 instances. The only part of it that would be funky is that you'd have to
 have an `add_action()` inside of `WP_Query`, after the main query had been
 run. Anyway, this makes the lazyloading automatic for all query objects,
 and removes a bunch of the checks done in the original implementation
 (`$wp_query instanceof WP_Query`), etc. See [attachment:34047.diff].

 Does this make sense to you?

 If so, let's do the same thing for commentmeta lazy loading.

--
Ticket URL: <https://core.trac.wordpress.org/ticket/34047#comment:1>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list