ensureColons static method
Wrap colons on both sides of emoji name. So, 'heart' will become ':heart:'.
Implementation
static String ensureColons(String name) {
var res = name;
if ('${name[0]}' != EmojiConst.charColon) {
res = EmojiConst.charColon + name;
}
if (!name.endsWith(EmojiConst.charColon)) {
res += EmojiConst.charColon;
}
return res;
}