When this happens the HVAC unit is idle, and you simply don't don't do anything, none of the set points have changed, nor has thermostatMode...
null and undefined aren't values defined for thermostatMode or thermostatOperatingState so any apps which may use either of these attributes aren't going to do well if they see a null or undefined value here.
A special case exists when thermostats have and are set to auto mode, you need to manually track the mode so you know how to update the setpoints, we do this via updateDataValue("lastRunningMode",lastRunningMode)
Thermostats are probably the most complex drivers to implement correctly due to all of these operational complexities.