style, fix bug, change index