Refactored code to use variables for later features.