Need to use data.updateProperties instead of setting the properties myself.