update doc and change ensure