Made command use dependency injection