From 155c4b832281348c16be1f4ef667e6e23dbf1bd8 Mon Sep 17 00:00:00 2001 From: Vijay Raghavan Aravamudhan Date: Fri, 27 Aug 2021 18:13:24 +0530 Subject: chore: normalized all recipes to ensure compatibility with es6 (#639) - Removed some calls to set badge with '0' all the time. - Removed all 'sourceMaps' since they are all outdated atm. --- recipes/zeplin/webview.js | 12 +++--------- 1 file changed, 3 insertions(+), 9 deletions(-) (limited to 'recipes/zeplin/webview.js') diff --git a/recipes/zeplin/webview.js b/recipes/zeplin/webview.js index 00030b0..445eebe 100644 --- a/recipes/zeplin/webview.js +++ b/recipes/zeplin/webview.js @@ -1,15 +1,9 @@ -const path = require('path'); - -module.exports = Franz => { +module.exports = Ferdi => { const getMessages = () => { const totalNotifications = document.querySelectorAll('#notificationList > .notification').length; const hasUnread = document.querySelectorAll('#notificationsButton.hasUnread').length > 0; - - // set Franz badge - if (hasUnread) { - Franz.setBadge(totalNotifications); - } + Ferdi.setBadge(hasUnread ? totalNotifications : 0); }; - Franz.loop(getMessages); + Ferdi.loop(getMessages); }; -- cgit v1.2.3-70-g09d2