mirror of
https://github.com/twitter/twemoji.git
synced 2024-06-15 03:35:16 +00:00
Merge ad1fc0e48d
into 55443d4b39
This commit is contained in:
commit
7de36b890c
10
2/twemoji.js
10
2/twemoji.js
@ -516,6 +516,14 @@ var twemoji = (function (
|
|||||||
}
|
}
|
||||||
|
|
||||||
function parse(what, how) {
|
function parse(what, how) {
|
||||||
|
// first argument can only be string or HTML Element
|
||||||
|
if (
|
||||||
|
typeof what !== 'string' &&
|
||||||
|
!(what && what.nodeName)
|
||||||
|
) {
|
||||||
|
return what;
|
||||||
|
}
|
||||||
|
|
||||||
if (!how || typeof how === 'function') {
|
if (!how || typeof how === 'function') {
|
||||||
how = {callback: how};
|
how = {callback: how};
|
||||||
}
|
}
|
||||||
@ -564,4 +572,4 @@ var twemoji = (function (
|
|||||||
return r.join(sep || '-');
|
return r.join(sep || '-');
|
||||||
}
|
}
|
||||||
|
|
||||||
}());
|
}());
|
||||||
|
Loading…
Reference in New Issue
Block a user