add verify_code function to user