Fixed variable names and comments