[wp-trac] [WordPress Trac] #38132: Remove orphaned postmeta
WordPress Trac
noreply at wordpress.org
Mon Apr 1 19:36:24 UTC 2019
#38132: Remove orphaned postmeta
--------------------------------+----------------------
Reporter: lukecavanagh | Owner: (none)
Type: feature request | Status: closed
Priority: normal | Milestone:
Component: Options, Meta APIs | Version:
Severity: normal | Resolution: wontfix
Keywords: | Focuses:
--------------------------------+----------------------
Changes (by desrosj):
* status: new => closed
* resolution: => wontfix
* milestone: Awaiting Review =>
Comment:
I'm going to close this out as a `wontfix`.
I do not think Core should make assumptions about what post meta is "no
longer being used".
- There is currently no way to tell when post meta is updated or utilized.
- It's not uncommon for post meta to be set once and never change.
- If meta remains after using `wp_delete_post()` (or remains "orphaned",
in general), then we should look into why this happens and fix it.
- If a plugin, theme, or custom code is using a direct query to remove a
post, then they should be educated on the benefits of using
`wp_delete_post()`.
Expired session data stored in transients, as referenced in the
description, is a much different use case. Transients have an explicit
expiration timestamp that defines when data should no longer be used.
--
Ticket URL: <https://core.trac.wordpress.org/ticket/38132#comment:5>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list