Refactored to make linting happy