function user_delete_user_cancel in User Delete 6.2
Implements hook_user_cancel();
From here to bottom, default node, comments and the rest of modules hook_user_cancel implementation handled by Drupal 7.
Node updates are done in batch.
File
- ./
user_delete.module, line 534 - Provide account cancellation methods and API to provide the same functionalty as Drupal 7 for cancelling accounts.
Code
function user_delete_user_cancel($edit, $account, $method) {
switch ($method) {
// This method has nothing to do with content.
case 'user_cancel_block':
break;
// Take all content and unpublish.
case 'user_cancel_block_unpublish':
user_delete_node_cancel($edit, $account, $method);
user_delete_comment_cancel($edit, $account, $method);
//@TODO: update poll_vote to uid -> 0
break;
// The user will be deleted, reassign all content to uid 0.
case 'user_cancel_reassign':
user_delete_node_cancel($edit, $account, $method);
user_delete_comment_cancel($edit, $account, $method);
//@TODO: update poll_vote to uid -> 0
break;
// In this case the user and all content will really be deleted.
case 'user_cancel_delete':
user_delete_node_cancel($edit, $account, $method);
user_delete_comment_cancel($edit, $account, $method);
break;
}
}