update
clean up all other function, keep the core function