another refactoring

processLocation