Proper dependency injection