[wp-trac] [WordPress Trac] #33404: Customizer Menus: Search results can have duplicate items

WordPress Trac noreply at wordpress.org
Fri Oct 23 04:58:09 UTC 2015


#33404: Customizer Menus: Search results can have duplicate items
-------------------------------------+-----------------------------
 Reporter:  valendesigns             |       Owner:  valendesigns
     Type:  defect (bug)             |      Status:  assigned
 Priority:  normal                   |   Milestone:  4.3.2
Component:  Customize                |     Version:  4.3
 Severity:  normal                   |  Resolution:
 Keywords:  has-patch needs-testing  |     Focuses:  administration
-------------------------------------+-----------------------------
Changes (by valendesigns):

 * keywords:  needs-patch needs-unit-tests => has-patch needs-testing


Comment:

 This is fixed with [attachment:33404.2.diff]. The issue was the
 combination of `number` and `offset` when using `get_terms` that when the
 offset was higher than the number of terms would return all of the terms.
 I fixed this by passing an array of term IDs to exclude from the query and
 removing `offset`.

 As well, if the content height is taller than the first page of search
 results the JS initiates a scroll event to get the second page and fill up
 the empty space. This is needed because you can't initiate scroll events
 when the content area is taller than the query items.

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


More information about the wp-trac mailing list