Correct small issues with ordering and logout