Fix typo in defining update function.