Opened 2 months ago
Last modified 2 months ago
#62870 new enhancement
Autosave Stores Default Taxonomy (Category) but Not Custom Taxonomies
Reported by: |
|
Owned by: | |
---|---|---|---|
Milestone: | Awaiting Review | Priority: | normal |
Severity: | normal | Version: | |
Component: | Autosave | Keywords: | |
Focuses: | Cc: |
Description
In the WordPress block editor, the autosave feature correctly stores terms from the default taxonomy category
, but it fails to store terms from custom taxonomies. As a result, custom taxonomy terms assigned to a post are lost when relying on autosave, unless the post is manually saved.
Steps to Reproduce:
- Create a custom taxonomy using
register_taxonomy()
in WordPress and make sureshow_in_rest = true
. - Assign the custom taxonomy to a post type.
- Open the block editor for the post type.
- Assign terms to both the default taxonomy (category) and the custom taxonomy.
- Wait for the autosave to trigger.
- Reload the editor without manually saving the post.
Expected Behavior:
Terms for both the default taxonomy (category) and the custom taxonomy should be stored and restored by autosave.
Actual Behavior:
Terms for the default taxonomy (category) are stored and restored correctly.
Terms for the custom taxonomy are not stored, resulting in data loss.
Change History (2)
Note: See
TracTickets for help on using
tickets.
Hi @praful2111,
I followed your steps but couldn't replicate the specific issue. I noticed that during autosave, only post content, title, and excerpt are being saved. Neither default nor custom taxonomies are being saved in the autosave process.