Ghost/ghost
Simon Backx 3db434736b
🐛 Fixed replacements with fallback in plaintext newsletters (#16372)
fixes https://github.com/TryGhost/Team/issues/2683

When sending a newsletter with a replacement that has a fallback, the
replacement only happens in the HTML version of the newsletter. The
plaintext version isn't replaced.

This commit fixes the issue and adds some tests to make sure it doesn't
happen again.

The cause of the issue was that we used the original matched Regex text
to replace. But that was calculated on the HTML version, so double
quotes were encoded. This change updates the generated 'token' regex to
also match on both a double quote as the escaped double quote.
2023-03-07 15:34:43 +01:00
..
adapter-cache-memory-ttl Commented out flaky adapter-cache-memory-ttl tests 2023-02-22 17:24:26 +01:00
adapter-cache-redis Update dependency c8 to v7.13.0 2023-02-16 22:15:50 +00:00
adapter-manager Updated sinon dependency 2023-03-02 12:43:42 +01:00
admin 🐛 Fixed ability to cancel Stripe subscriptio when deleting member 2023-03-07 10:38:04 +01:00
api-framework Updated sinon dependency 2023-03-02 12:43:42 +01:00
api-version-compatibility-service Updated sinon dependency 2023-03-02 12:43:42 +01:00
audience-feedback Updated sinon dependency 2023-03-02 12:43:42 +01:00
bootstrap-socket Updated sinon dependency 2023-03-02 12:43:42 +01:00
constants Updated sinon dependency 2023-03-02 12:43:42 +01:00
core 🐛 Fixed replacements with fallback in plaintext newsletters (#16372) 2023-03-07 15:34:43 +01:00
custom-theme-settings-service Updated sinon dependency 2023-03-02 12:43:42 +01:00
data-generator Updated sinon dependency 2023-03-02 12:43:42 +01:00
domain-events Update @tryghost 2023-03-02 09:47:02 +01:00
dynamic-routing-events Update dependency c8 to v7.13.0 2023-02-16 22:15:50 +00:00
email-analytics-provider-mailgun Updated sinon dependency 2023-03-02 12:43:42 +01:00
email-analytics-service Updated sinon dependency 2023-03-02 12:43:42 +01:00
email-content-generator Update dependency c8 to v7.13.0 2023-02-16 22:15:50 +00:00
email-events Updated sinon dependency 2023-03-02 12:43:42 +01:00
email-service 🐛 Fixed replacements with fallback in plaintext newsletters (#16372) 2023-03-07 15:34:43 +01:00
email-suppression-list Updated sinon dependency 2023-03-02 12:43:42 +01:00
event-aware-cache-wrapper Added missing dev dependency to event-aware-cache-wrapper package 2023-02-23 08:48:01 +01:00
express-dynamic-redirects Update dependency c8 to v7.13.0 2023-02-16 22:15:50 +00:00
external-media-inliner Fixed inlined media storage path 2023-03-07 18:42:58 +08:00
extract-api-key Fixed full Admin test suite running during unit tests 2022-08-15 15:34:52 +02:00
html-to-plaintext Update dependency c8 to v7.13.0 2023-02-16 22:15:50 +00:00
i18n Fixed linting 2023-03-01 10:30:18 +01:00
importer-handler-content-files Refactored importer's content file handler 2023-03-02 17:54:19 +08:00
importer-revue Update @tryghost 2023-03-02 09:47:02 +01:00
job-manager Updated sinon dependency 2023-03-02 12:43:42 +01:00
link-redirects Updated sinon dependency 2023-03-02 12:43:42 +01:00
link-replacer Updated sinon dependency 2023-03-02 12:43:42 +01:00
link-tracking Updated sinon dependency 2023-03-02 12:43:42 +01:00
magic-link Updated sinon dependency 2023-03-02 12:43:42 +01:00
mailgun-client Updated sinon dependency 2023-03-02 12:43:42 +01:00
member-attribution Updated sinon dependency 2023-03-02 12:43:42 +01:00
member-events Updated sinon dependency 2023-03-02 12:43:42 +01:00
members-api 🎨 Added source attribution info to email alerts (#16360) 2023-03-06 15:06:47 +05:30
members-csv Updated sinon dependency 2023-03-02 12:43:42 +01:00
members-events-service Updated sinon dependency 2023-03-02 12:43:42 +01:00
members-importer Updated sinon dependency 2023-03-02 12:43:42 +01:00
members-ssr Updated sinon dependency 2023-03-02 12:43:42 +01:00
milestones Fixed tests 2023-02-23 17:21:20 +02:00
minifier Updated sinon dependency 2023-03-02 12:43:42 +01:00
mw-api-version-mismatch Updated sinon dependency 2023-03-02 12:43:42 +01:00
mw-cache-control Updated sinon dependency 2023-03-02 12:43:42 +01:00
mw-error-handler Updated sinon dependency 2023-03-02 12:43:42 +01:00
mw-session-from-token Updated sinon dependency 2023-03-02 12:43:42 +01:00
mw-update-user-last-seen Updated sinon dependency 2023-03-02 12:43:42 +01:00
mw-version-match Update @tryghost 2023-03-02 09:47:02 +01:00
mw-vhost Update dependency c8 to v7.13.0 2023-02-16 22:15:50 +00:00
oembed-service Update @tryghost 2023-03-02 09:47:02 +01:00
offers Updated sinon dependency 2023-03-02 12:43:42 +01:00
package-json Updated sinon dependency 2023-03-02 12:43:42 +01:00
payments Updated sinon dependency 2023-03-02 12:43:42 +01:00
portal Update sentry-javascript monorepo to v7.41.0 2023-03-07 06:51:35 +01:00
referrers Updated sinon dependency 2023-03-02 12:43:42 +01:00
security Updated sinon dependency 2023-03-02 12:43:42 +01:00
session-service Updated sinon dependency 2023-03-02 12:43:42 +01:00
settings-path-manager Updated sinon dependency 2023-03-02 12:43:42 +01:00
slack-notifications Update @tryghost 2023-03-02 09:47:02 +01:00
staff-service Refined new signup email templates 2023-03-07 14:19:30 +01:00
stats-service Updated sinon dependency 2023-03-02 12:43:42 +01:00
stripe Updated sinon dependency 2023-03-02 12:43:42 +01:00
tiers Update @tryghost 2023-03-02 09:47:02 +01:00
update-check-service Updated sinon dependency 2023-03-02 12:43:42 +01:00
verification-trigger Updated sinon dependency 2023-03-02 12:43:42 +01:00
version-notifications-data-service Updated sinon dependency 2023-03-02 12:43:42 +01:00
webmentions Update @tryghost 2023-03-02 09:47:02 +01:00