update functions, not completed yet