Added dependency injection