Fixed username issue

Fixed username issue and some other minor issues