update debugging, fixed update bug