The check_previous_meta function in radium-importer.php conflicts with meta field options. This can be replicated using the WP Job Manager plugin. When checking a checkbox on job posts the checkbox does not remaine checked once you save the post. As soon as this function is removed the checkbox stays checked when the post is saved.
For now I'm running a check to only use this function on themes.php using $pagenow:
global $pagenow;
if ( $pagenow === 'themes.php' ) {
add_filter( 'add_post_metadata', array( $this, 'check_previous_meta' ), 10, 5 );
}
Will this code still be run when importing demo data? Is there a better alternative to this?
The check_previous_meta function in radium-importer.php conflicts with meta field options. This can be replicated using the WP Job Manager plugin. When checking a checkbox on job posts the checkbox does not remaine checked once you save the post. As soon as this function is removed the checkbox stays checked when the post is saved.
For now I'm running a check to only use this function on themes.php using $pagenow:
Will this code still be run when importing demo data? Is there a better alternative to this?