Basically logout function now works