location function changes