Refactored for more readability.