-
Notifications
You must be signed in to change notification settings - Fork 99
save_term_fields() does not check the term ID, can result in data corruption #831
Copy link
Copy link
Closed
Description
The save_fields_for_post() method in the post context has a guard condition where it checks the post ID before saving data to it. This is for the situation where another post gets updated when a post is saved and prevents meta data being saved to another post. Ref:
| // Make sure this hook fired on the post being saved, not a side-effect post for which the $_POST context is invalid. |
This was introduced in #147.
There is no such protection for terms. If a term gets saved and some code updates another term, Fieldmanager will write its term meta to that term too. Ref:
| public function save_term_fields( $term_id, $tt_id, $taxonomy ) { |
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels