phone home: code refactoring. Refs#2975