update and fix bug