@chrisjluc - Refactored code