Login/Logout functions now work properly (closes #5), a bit of beautification and minor deletions