refactor Location provider