You've already forked matrix-react-sdk
mirror of
https://github.com/matrix-org/matrix-react-sdk.git
synced 2025-11-07 10:46:24 +03:00
Apply code review suggestion
Signed-off-by: Robin Townsend <robin@robin.town>
This commit is contained in:
@@ -80,7 +80,7 @@ function mightContainEmoji(str: string): boolean {
|
||||
*/
|
||||
export function unicodeToShortcode(char: string): string {
|
||||
const shortcodes = getEmojiFromUnicode(char)?.shortcodes;
|
||||
return shortcodes && shortcodes.length > 0 ? `:${shortcodes[0]}:` : '';
|
||||
return shortcodes?.length ? `:${shortcodes[0]}:` : '';
|
||||
}
|
||||
|
||||
export function processHtmlForSending(html: string): string {
|
||||
|
||||
Reference in New Issue
Block a user