mirror of
https://github.com/dilllxd/gitfolio.git
synced 2024-08-14 22:28:09 +00:00
remove host workaround for emoji URLs since github-emoji v1.1.1 fixed it (#94)
This commit is contained in:
parent
5717f17eff
commit
0e90c885d1
2 changed files with 2 additions and 7 deletions
|
@ -38,7 +38,7 @@
|
||||||
"commander": "^2.20.0",
|
"commander": "^2.20.0",
|
||||||
"ejs": "^2.6.2",
|
"ejs": "^2.6.2",
|
||||||
"express": "^4.17.0",
|
"express": "^4.17.0",
|
||||||
"github-emoji": "^1.1.0",
|
"github-emoji": "^1.1.1",
|
||||||
"got": "^9.6.0",
|
"got": "^9.6.0",
|
||||||
"handlebars": "^4.1.2",
|
"handlebars": "^4.1.2",
|
||||||
"jsdom": "^15.1.0",
|
"jsdom": "^15.1.0",
|
||||||
|
|
|
@ -18,14 +18,9 @@ function convertToEmoji(text) {
|
||||||
});
|
});
|
||||||
for (i = 0; i < str.length; i++) {
|
for (i = 0; i < str.length; i++) {
|
||||||
if (emoji.URLS[str[i]] != undefined) {
|
if (emoji.URLS[str[i]] != undefined) {
|
||||||
var output = emoji.of(str[i]);
|
|
||||||
var emojiImage = output.url.replace(
|
|
||||||
"assets-cdn.github",
|
|
||||||
"github.githubassets"
|
|
||||||
);
|
|
||||||
text = text.replace(
|
text = text.replace(
|
||||||
`:${str[i]}:`,
|
`:${str[i]}:`,
|
||||||
`<img src="${emojiImage}" class="emoji">`
|
`<img src="${emoji.URLS[str[i]]}" class="emoji">`
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue