Refactoring processResults