Implemented the repository pattern and Unit of Work