method for updating maps