Refactored and commented uow structure.