Sorted a few bugs and added a logout out button.