From 93f117e76f51a34f3242e88bcfa04cd61862b0b7 Mon Sep 17 00:00:00 2001 From: Monica Dinculescu Date: Thu, 20 Jul 2017 16:44:04 -0700 Subject: [PATCH] hardcode thanks --- emoji-translate.js | 2 ++ test.js | 1 + 2 files changed, 3 insertions(+) diff --git a/emoji-translate.js b/emoji-translate.js index 657921ba..80cd2115 100644 --- a/emoji-translate.js +++ b/emoji-translate.js @@ -73,6 +73,8 @@ function getAllEmojiForWord(originalWord) { useful.push('👩‍👩‍👦‍👦'); } else if (word === 'am' || word === 'is' || word === 'are') { useful.push('👉'); + } else if (word === 'thanks') { + useful.push('🙌'); } for (let emoji in allEmoji) { diff --git a/test.js b/test.js index 08661fa0..5c391e60 100644 --- a/test.js +++ b/test.js @@ -60,6 +60,7 @@ test('hard coded words', function(t) { t.notEqual('i am', translate.translate('i am').trim()); t.notEqual('she he is', translate.translate('she he is').trim()); t.notEqual('we they are', translate.translate('we they are').trim()); + t.equal('🙌', translate.translate('thanks').trim()); t.end(); });