fixed map location function