Renamed some variables to make the code clearer and fixed some paths