Make emote command minimum length 4 characters to get rid of garbage emotes
This commit is contained in:
parent
f211b26621
commit
306a00152a
|
@ -70,6 +70,10 @@ EmoteModule.prototype.injectEmote = function(node) {
|
|||
|
||||
words.some(function(word) {
|
||||
|
||||
if(word.length < 4) {
|
||||
return;
|
||||
}
|
||||
|
||||
if(emotesTwitch.emotes.hasOwnProperty(word)) {
|
||||
parentInnerHTML = parentInnerHTML.replace(word, "<img src=" + twitchEmoteUrlStart + emotesTwitch.emotes[word].image_id + twitchEmoteUrlEnd + " ><\/img>");
|
||||
return;
|
||||
|
|
|
@ -230,6 +230,10 @@ EmoteModule.prototype.injectEmote = function(node) {
|
|||
|
||||
if($.inArray(word, bemotes) != -1) return;
|
||||
|
||||
if(word.length < 4) {
|
||||
return;
|
||||
}
|
||||
|
||||
if(emotesTwitch.emotes.hasOwnProperty(word)) {
|
||||
parentInnerHTML = parentInnerHTML.replace(word, "<img src=" + twitchEmoteUrlStart + emotesTwitch.emotes[word].image_id + twitchEmoteUrlEnd + " ><\/img>");
|
||||
return;
|
||||
|
|
File diff suppressed because one or more lines are too long
Loading…
Reference in New Issue