[wp-meta] [Making WordPress.org] #866: Themes search API returns invalid result when `per_page=1`

Making WordPress.org noreply at wordpress.org
Mon Feb 16 17:24:28 UTC 2015


#866: Themes search API returns invalid result when `per_page=1`
------------------------------+-------------------------------
  Reporter:  danielbachhuber  |      Owner:
      Type:  defect           |     Status:  new
  Priority:  normal           |  Component:  api.wordpress.org
Resolution:                   |   Keywords:
------------------------------+-------------------------------

Comment (by obenland):

 The API uses a regular `BB_Query` to get its search results. These results
 are then checked for exact matches to be bumped to the top. In cases where
 the exact match happens to be on a subsequent page, that bumping obviously
 can't take place - leading to the unexpected result.

 Unfortunately there is no great solution to this problem. We could ignore
 the `per_page` and `page` argument for search queries and do paging after
 the results were bumped, which would help in the case of P2 and maybe
 Responsive. But if there happens to be a theme called Black that is close
 to two years old, it will be buried under newer themes that might have the
 word "black" in their description.

--
Ticket URL: <https://meta.trac.wordpress.org/ticket/866#comment:1>
Making WordPress.org <https://meta.trac.wordpress.org/>
Making WordPress.org


More information about the wp-meta mailing list