Fixed variable names that were creating issues