Avoid overriding id when it hasn't changed.