In the console in the browser is see this:
mxui.js?636433354971055256:5 mxui_widget_DataView_3.destroy: Unable to destroy:ReCaptcha_ReCaptchaWidget_ReCaptchaWidget_1.uninitialize: TypeError: Cannot read property 'remove' of null
error @ mxui.js?636433354971055256:5
(anonymous) @ mxui.js?636433354971055256:5
forEach @ mxui.js?636433354971055256:5
t.exports.destroyWidgetsIn @ mxui.js?636433354971055256:5
destroy @ mxui.js?636433354971055256:15
(anonymous) @ mxui.js?636433354971055256:15
a @ mxui.js?636433354971055256:5
(anonymous) @ mxui.js?636433354971055256:15
_fire @ mxui.js?636433354971055256:5
_cycle @ mxui.js?636433354971055256:5
(anonymous) @ mxui.js?636433354971055256:5
a @ mxui.js?636433354971055256:5
(anonymous) @ mxui.js?636433354971055256:5
In the source the error is located in the bold code line:
* Called upon completion of the microflow
* Create the ReCaptcha
*
* @param resultArray
*/
configurationMicroflowCallback: function (resultArray) {
var reCaptchaCreateArgs;
if (resultArray === "") {
console.log("No Recaptcha configuration found");
return;
}
this.configurationObject = resultArray[0];
if (this.buttonIcon === 'not-set') {
this.buttonIcon = null;
}
try {
this.submitButton = new mendix.widget._Button({
caption: this.caption,
icon: this.buttonIcon,
type: this.showAsButton.toLowerCase(),
cssclass: "recaptcha-button"
});
this.buttonOnClickHandle = on(this.submitButton.domNode, 'click', lang.hitch(this, this.onButtonClick));
} catch (e) {
console.error("Button render exception: " + e);
return;
}
this.domNode.appendChild(this.submitButton.domNode);
reCaptchaCreateArgs = {theme: this.theme};
if (this.focusRecaptchaInput) {
reCaptchaCreateArgs.callback = Recaptcha.focus_response_field;
}
Recaptcha.create(this.configurationObject.get(this.publicKeyAttr), 'captchadiv', reCaptchaCreateArgs);
},