Added checking for when a user leaves, modified the ui