added logout and stuff