Allow variation selection in emoji search results.

This commit is contained in:
Greyson Parrelli
2021-06-03 21:18:12 -04:00
parent 115e74d844
commit 45c587c5e4
3 changed files with 17 additions and 21 deletions

View File

@@ -49,7 +49,7 @@ public final class EmojiUtil {
* If the emoji has no skin variations, this function will return the original emoji.
*/
public static @NonNull String getCanonicalRepresentation(@NonNull String emoji) {
String canonical = EmojiSource.getLatest().getVariationMap().get(emoji);
String canonical = EmojiSource.getLatest().getVariationsToCanonical().get(emoji);
return canonical != null ? canonical : emoji;
}