implement a (hopefully) better way to check whether update functions need to be run