Add check for changed attributes