fix merged region bug