some refactoring done, no username now