mirror of
https://github.com/10h30/ultimatemember.git
synced 2026-06-05 15:09:37 +09:00
13 lines
328 B
PHP
13 lines
328 B
PHP
<?php
|
|
|
|
/***
|
|
*** @prevent moving core posts to trash
|
|
***/
|
|
add_action('wp_trash_post','um_core_posts_delete');
|
|
function um_core_posts_delete($post_id){
|
|
global $ultimatemember;
|
|
if ( $ultimatemember->query->is_core($post_id) ) {
|
|
wp_die('This is a core functionality of Ultimate Member and cannot be deleted!');
|
|
}
|
|
|
|
} |