updating two maps