Change unsubscribe verifier to check for "Unsubscribe" shortcode
presence
This commit is contained in:
@@ -62,6 +62,7 @@ define([
|
|||||||
invalid_elements: "script",
|
invalid_elements: "script",
|
||||||
block_formats: 'Paragraph=p',
|
block_formats: 'Paragraph=p',
|
||||||
relative_urls: false,
|
relative_urls: false,
|
||||||
|
remove_script_host: false,
|
||||||
|
|
||||||
plugins: "link textcolor colorpicker mailpoet_custom_fields",
|
plugins: "link textcolor colorpicker mailpoet_custom_fields",
|
||||||
|
|
||||||
|
@@ -62,6 +62,7 @@ define([
|
|||||||
invalid_elements: "script",
|
invalid_elements: "script",
|
||||||
block_formats: 'Paragraph=p',
|
block_formats: 'Paragraph=p',
|
||||||
relative_urls: false,
|
relative_urls: false,
|
||||||
|
remove_script_host: false,
|
||||||
|
|
||||||
plugins: "link textcolor colorpicker mailpoet_custom_fields",
|
plugins: "link textcolor colorpicker mailpoet_custom_fields",
|
||||||
|
|
||||||
|
@@ -60,6 +60,7 @@ define([
|
|||||||
invalid_elements: "script",
|
invalid_elements: "script",
|
||||||
block_formats: 'Heading 1=h1;Heading 2=h2;Heading 3=h3;Paragraph=p',
|
block_formats: 'Heading 1=h1;Heading 2=h2;Heading 3=h3;Paragraph=p',
|
||||||
relative_urls: false,
|
relative_urls: false,
|
||||||
|
remove_script_host: false,
|
||||||
|
|
||||||
plugins: "link code textcolor colorpicker mailpoet_custom_fields",
|
plugins: "link code textcolor colorpicker mailpoet_custom_fields",
|
||||||
|
|
||||||
|
@@ -283,8 +283,10 @@ define([
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
var contents = JSON.stringify(jsonObject);
|
||||||
if (App.getConfig().get('validation.validateUnsubscribeLinkPresent') &&
|
if (App.getConfig().get('validation.validateUnsubscribeLinkPresent') &&
|
||||||
JSON.stringify(jsonObject).indexOf("[link:subscription_unsubscribe_url]") < 0) {
|
contents.indexOf("[link:subscription_unsubscribe_url]") < 0 &&
|
||||||
|
contents.indexOf("[link:subscription_unsubscribe]") < 0) {
|
||||||
this.showValidationError(MailPoet.I18n.t('unsubscribeLinkMissing'));
|
this.showValidationError(MailPoet.I18n.t('unsubscribeLinkMissing'));
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user