diff options
author | Kushal Pandya <kushalspandya@gmail.com> | 2017-04-20 14:11:51 +0300 |
---|---|---|
committer | Filipa Lacerda <filipa@gitlab.com> | 2017-04-20 14:11:51 +0300 |
commit | d586b6cced34d663f018203e99aecbb9c6ac3158 (patch) | |
tree | dd01b08da4233d1b27762021fa9919a2708d12f9 /app/assets/javascripts/awards_handler.js | |
parent | f96e1bf12432b0f4eff4a900caa46a0c4790123f (diff) |
Add ES lint support to identify poorly written Promises
Diffstat (limited to 'app/assets/javascripts/awards_handler.js')
-rw-r--r-- | app/assets/javascripts/awards_handler.js | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/app/assets/javascripts/awards_handler.js b/app/assets/javascripts/awards_handler.js index f93208944a1..adb45b0606d 100644 --- a/app/assets/javascripts/awards_handler.js +++ b/app/assets/javascripts/awards_handler.js @@ -239,6 +239,9 @@ AwardsHandler if (menu) { menu.dispatchEvent(new CustomEvent('build-emoji-menu-finish')); } + }).catch((err) => { + emojiContentElement.insertAdjacentHTML('beforeend', '<p>We encountered an error while adding the remaining categories</p>'); + throw new Error(`Error occurred in addRemainingEmojiMenuCategories: ${err.message}`); }); }; |