Fixed regression bug on updating