How to allow users to cancel their own account? I gave the permission cancel own user account to authenticated users.

Now they can see a Cancel account button on their profile edit.

But when they click on that button, a confirmation form opens. That is fine.

On the confirmation form, when they click on the Cancel account, they are redirected to their profile page with a message 

A confirmation request to cancel your account has been sent to your email address.

I want to change this functionality. When they click on cancel account, they should not receive a confirmation cancellation email. Their account should be deleted immediately and they should be gets logged out.

I tried with this code but it is not working.

$form['user_cancel_confirm']['#default_value'] = FALSE;

Is this possible? How can I do this?
Seems the Cancel Account Separate Form module does exactly what you want. It provides a form that finally calls user_cancel with the current user's UID as parameter.


  This is a very simple, lightweight module that provides cancel user
  account separate form and adds it to user edit form by default if user
  has cancel account permissions and edits his own account.