Skip to content

[my_preferences] Allow emojis#10900

Open
lapadulamichael wants to merge 4 commits into
aces:29.0-releasefrom
lapadulamichael:2026_07_13_Fix_emojis_wont_save_my_preferences
Open

[my_preferences] Allow emojis#10900
lapadulamichael wants to merge 4 commits into
aces:29.0-releasefrom
lapadulamichael:2026_07_13_Fix_emojis_wont_save_my_preferences

Conversation

@lapadulamichael

@lapadulamichael lapadulamichael commented Jul 13, 2026

Copy link
Copy Markdown
Contributor

Brief summary of changes

In the my_preference module, allow saving First Name, Last Name and/or Email with emojis

  • Changed the charset to utf8mb4 when creating the PDO for db connection
  • Altered users and history table to utf8mb4

Testing instructions (if applicable)

  1. Run the patch
  2. Go to my_preferences
  3. Try saving with First Name, Last Name and/or Email containing emojis

Link(s) to related issue(s)

  • Resolves 10848 (Reference the issue this fixes, if any.)

@github-actions github-actions Bot added Language: SQL PR or issue that update SQL code Language: PHP PR or issue that update PHP code labels Jul 13, 2026
@lapadulamichael lapadulamichael added the 29.0.0 - Bugs Issues found during the release testing for 29.0.0 label Jul 13, 2026
@lapadulamichael lapadulamichael changed the title Change db charset to utf8mb4 [my_preferences] Allow emojis Jul 13, 2026
MODIFY userID varchar(255) CHARACTER SET utf8mb4 NOT NULL DEFAULT '',
MODIFY type char(1) CHARACTER SET utf8mb4 NULL DEFAULT NULL;

ALTER TABLE users

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

  1. This default schema needs to be modified as well
  2. Shouldn't we just modify the charset for the table instead of doing it individually for each column?

MODIFY primaryCols text CHARACTER SET utf8mb4 NULL DEFAULT NULL,
MODIFY primaryVals text CHARACTER SET utf8mb4 NULL DEFAULT NULL,
MODIFY userID varchar(255) CHARACTER SET utf8mb4 NOT NULL DEFAULT '',
MODIFY type char(1) CHARACTER SET utf8mb4 NULL DEFAULT NULL;

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

I think this table should have the charset modified on the table level instead of individual columns as well, but if it is done for individual columns this one can never store an emoji anyways.. it's 1 byte and hardcoded in the code

@lapadulamichael lapadulamichael force-pushed the 2026_07_13_Fix_emojis_wont_save_my_preferences branch from 9693641 to 9117aec Compare July 14, 2026 18:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

29.0.0 - Bugs Issues found during the release testing for 29.0.0 Language: PHP PR or issue that update PHP code Language: SQL PR or issue that update SQL code

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants