added semi-completed code for close account function