update according to diagram changes