Initial work on improved logout.