updated all preexisting funtcions