Enhanced Conversions not working anymore

Hello,
For quite some time I was using this script for HS enhanced conversions:

<script type="text/javascript">
 window.addEventListener("message", function(event) {
 if(event.data.type === 'hsFormCallback' && event.data.eventName === 'onFormSubmitted') {
 window.dataLayer.push({
 'event': 'hubspot_form_success',
 'hs-form-guid': event.data.id,
 'email': Object.keys(hubspot._emailValidationAndResubCache)[0]
 });
 }
 });
</script>

Its one of the most popular enhanced conversions scripts out there - it was working like a charm up until last month, when all of the sudden script refused to work unless I deleted the

'email': Object.keys(hubspot._emailValidationAndResubCache)[0]

part (which is the one providing the enhanced conversion data.

Any way to get Enhanced Conversions back to Hubspot-based forms?

Hello @Waran, thank you for providing this information. I checked more about it and at the moment, Google Enhanced Conversions is currently being worked on by our internal product team but is not yet available. Are you using a beta version?

Kindly,

Pam