Opened 10 years ago
Closed 10 years ago
#22903 closed defect (bug) (duplicate)
*_image_link can fail for unattached media items on large sites
Reported by: |
|
Owned by: | |
---|---|---|---|
Milestone: | Priority: | normal | |
Severity: | normal | Version: | |
Component: | Media | Keywords: | |
Focuses: | Cc: |
Description
On a site with many unattached media items (e.g. ~25,000), use of the *_image_link
functions can fail.
This is because the adjancent_image_link
function makes a get_children
call with post_parent = 0
, causing all unattached media items to be returned.
One possible optimization would be to return only IDs but that's likely to still fail when the unattached count is in the tens of thousands. It would be better to only query for the ID of the adjancent post.
Change History (1)
Note: See
TracTickets for help on using
tickets.
Closed in favor of #23044 since it's already in milestone and offers a temporary improvement.