| 38 | | do_action('comment_on_trash', $comment_post_ID); |
| 39 | | exit; |
| | 38 | /** |
| | 39 | * Allow comments on trashed posts. |
| | 40 | * |
| | 41 | * Allow comments on trashed posts, per #19739. |
| | 42 | * |
| | 43 | * @since 4.1.0 |
| | 44 | * |
| | 45 | * @param int $comment_post_ID The post_id for comments to be enabled on. |
| | 46 | */ |
| | 47 | if ( !apply_filters( 'allow_comment_on_trash', false, $comment_post_ID ) ){ |
| | 48 | do_action('comment_on_trash', $comment_post_ID); |
| | 49 | exit; |
| | 50 | } |
| 41 | | do_action('comment_on_draft', $comment_post_ID); |
| 42 | | exit; |
| | 52 | /** |
| | 53 | * Allow comments on draft posts. |
| | 54 | * |
| | 55 | * Allow comments on draft posts, per #19739. |
| | 56 | * |
| | 57 | * @since 4.1.0 |
| | 58 | * |
| | 59 | * @param int $comment_post_ID The post_id for comments to be enabled on. |
| | 60 | */ |
| | 61 | if ( !apply_filters( 'allow_comment_on_draft', false, $comment_post_ID ) ){ |
| | 62 | do_action('comment_on_draft', $comment_post_ID); |
| | 63 | exit; |
| | 64 | } |