fixed redo bug