Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

NV 546 fix: clipped blocked html #722

Merged

Conversation

djabarovgeorge
Copy link
Contributor

No description provided.

@linear
Copy link

linear bot commented Jun 23, 2022

NV-546 Email template is clipped due to large size on G-mail

When sending a simple email message the email is clipped by google due to email size.

CleanShot 2022-06-21 at 11.33.55.png

@vercel
Copy link

vercel bot commented Jun 23, 2022

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Updated
docs ✅ Ready (Inspect) Visit Preview Jun 26, 2022 at 0:32AM (UTC)

@gitpod-io
Copy link

gitpod-io bot commented Jun 23, 2022

@@ -203,7 +203,7 @@ export class SendMessageEmail extends SendMessageType {
const messageVariables = contentService.buildMessageVariables(command.payload, subscriber);
const content: IEmailBlock[] = [...emailChannel.template.content] as IEmailBlock[];
for (const block of content) {
block.content = contentService.replaceVariables(block.content, messageVariables);
block.content = contentService.replaceVariables(block.content, messageVariables).trim();
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maybe worth adding a comment here about why the .trim is important :P @djabarovgeorge

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Probably it worth the commit :)
Will do

@djabarovgeorge
Copy link
Contributor Author

@scopsy added note, let me know if you think its understandable

@scopsy
Copy link
Contributor

scopsy commented Jun 26, 2022

@djabarovgeorge Looks good! Let's merge it 🚀

@scopsy scopsy merged commit 0161411 into main Jun 27, 2022
@scopsy scopsy deleted the NV-546-Email-template-is-clipped-due-to-large-size-on-G-mail branch June 27, 2022 13:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants