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

Emoji in address notes breaks #1426

Closed
sjelfull opened this issue May 1, 2020 · 3 comments
Closed

Emoji in address notes breaks #1426

sjelfull opened this issue May 1, 2020 · 3 comments
Assignees
Labels

Comments

@sjelfull
Copy link
Contributor

sjelfull commented May 1, 2020

Description

A fair amount of customers adds emojis to their notes, breaking anywhere a address is being saved.

As an aside, would it be a good idea to add a new behaviour so that you can make the emoji cleanup universal for model attributes where users are likely to add emojis?

General error: 1366 Incorrect string value: '\xF0\x9F\x98\x89' for column 'notes' at row 1 The SQL being executed was: UPDATE `craft_commerce_addresses` SET `firstName`='xx', `lastName`='xx', `address1`='xx', 

Steps to reproduce

  1. Add emoji to customer notes when saving a address/updating a card
  2. Profit
@sjelfull
Copy link
Contributor Author

sjelfull commented May 7, 2020

@lukeholder Is this an easy fix? I'm seeing a fair amount of customers every day trying this, and my experience from other sites is the same: people like their emojis.

@lukeholder
Copy link
Member

We will be invalidating an address field that has an emoji submitted, and in the case of the address note, we will support converting emojis to shortcodes like we do for lines item notes. Will be in the release out early next week.

@lukeholder
Copy link
Member

Thanks, fixed for the next release.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants