mirror of
https://github.com/formbricks/formbricks.git
synced 2025-12-21 13:40:31 -06:00
fix: strict recaptcha checks (#5674)
This commit is contained in:
@@ -51,7 +51,7 @@ export const SurveyInline = (props: Omit<SurveyContainerProps, "containerId">) =
|
||||
const loadScript = async () => {
|
||||
if (!window.formbricksSurveys) {
|
||||
try {
|
||||
if (props.isSpamProtectionEnabled) {
|
||||
if (props.isSpamProtectionEnabled && props.recaptchaSiteKey) {
|
||||
await loadRecaptchaScript(props.recaptchaSiteKey);
|
||||
}
|
||||
await loadSurveyScript();
|
||||
|
||||
@@ -96,7 +96,7 @@ export const renderWidget = async (
|
||||
return executeRecaptcha(recaptchaSiteKey);
|
||||
};
|
||||
|
||||
if (isSpamProtectionEnabled) {
|
||||
if (isSpamProtectionEnabled && recaptchaSiteKey) {
|
||||
await loadRecaptchaScript(recaptchaSiteKey);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user