wp_untrash_post_set_previous_status() – Filter callback which sets the status of an untrashed post to its previous status.
You appear to be a bot. Output may be restricted
Description
Filters callback which sets the status of an untrashed post to its previous status.
This can be used as a callback on the wp_untrash_post_status
filter.
Usage
$string = wp_untrash_post_set_previous_status( $new_status, $post_id, $previous_status );
Parameters
- $new_status
- ( string ) required – The new status of the post being restored.
- $post_id
- ( int ) required – The ID of the post being restored.
- $previous_status
- ( string ) required – The status of the post at the point where it was trashed.
Returns
string The new status of the post.
Source
File name: wordpress/wp-includes/post.php
Lines:
1 to 3 of 3
function wp_untrash_post_set_previous_status( $new_status, $post_id, $previous_status ) { return $previous_status; }