updates the mapping