Update functions file