update_fold crashes unless params are reversed