mirror of
https://github.com/WordPress/five-for-the-future.git
synced 2025-07-04 10:05:43 +03:00
Hook up "Remove" button
This commit is contained in:
parent
d5c740ae84
commit
eacd2bf3f2
4 changed files with 59 additions and 11 deletions
|
@ -28,6 +28,14 @@ function handler() {
|
|||
'message' => sprintf( __( 'Confirmation email sent to %s.', 'wporg-5ftf' ), $contribution->post_title ),
|
||||
] ) );
|
||||
break;
|
||||
|
||||
case 'remove-contributor':
|
||||
// Trash contributor.
|
||||
Contributor\remove_contributor( $contributor_id );
|
||||
wp_die( wp_json_encode( [
|
||||
'success' => true,
|
||||
] ) );
|
||||
break;
|
||||
}
|
||||
|
||||
// No matching action, we can just exit.
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue