refactoring, events, repositories, file upload