Use same protocol as client was loaded over for recaptcha to prevent JS origin errors.
This commit is contained in:
parent
1b82d92fa1
commit
49c5f7cb95
1 changed files with 1 additions and 1 deletions
|
@ -90,7 +90,7 @@ module.exports = {
|
||||||
if (this.refs.recaptchaContainer) {
|
if (this.refs.recaptchaContainer) {
|
||||||
var scriptTag = document.createElement('script');
|
var scriptTag = document.createElement('script');
|
||||||
window.mx_on_recaptcha_loaded = this.onCaptchaLoaded;
|
window.mx_on_recaptcha_loaded = this.onCaptchaLoaded;
|
||||||
scriptTag.setAttribute('src', "https://www.google.com/recaptcha/api.js?onload=mx_on_recaptcha_loaded&render=explicit");
|
scriptTag.setAttribute('src', global.location.protocol+"//www.google.com/recaptcha/api.js?onload=mx_on_recaptcha_loaded&render=explicit");
|
||||||
this.refs.recaptchaContainer.getDOMNode().appendChild(scriptTag);
|
this.refs.recaptchaContainer.getDOMNode().appendChild(scriptTag);
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
Loading…
Add table
Reference in a new issue