Minor code refactoring for consistency.