Shipra
Forum Replies Created
Viewing 2 replies - 1 through 2 (of 2 total)
-
Hey @rizaardiyanto, I could track down the issue here. This was happening because of our modifications done to plugin. As we recently upgraded to latest version of plugin(we were earlier on 2.x version) and the EXPIRATION_ACTIONS have changed in newer versions so our filter was filtering incorrect actions leading to empty dropdowns. Modifiying our filter did the track & now I can use it as expected. Thanks.
we’ve only done these modifications to the plugin earlier, could this lead to the issue with latest version?
use PublishPress\Future\Modules\Expirator\ExpirationActionsAbstract;
use PublishPress\Future\Modules\Expirator\HooksAbstract;
add_filter( HooksAbstract::FILTER_EXPIRATION_ACTIONS, function ( $actions, $post_type ) {
$actions = array_intersect_key( $actions, [
ExpirationActionsAbstract::POST_STATUS_TO_DRAFT => true,
ExpirationActionsAbstract::POST_STATUS_TO_TRASH => true,
] );
//$actions['do_nothing'] = __( 'Do nothing', 'XYZ' );
return $actions;
}, 10, 2 );
Viewing 2 replies - 1 through 2 (of 2 total)