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/telegram/webview.js | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) (limited to 'recipes/telegram/webview.js') diff --git a/recipes/telegram/webview.js b/recipes/telegram/webview.js index db8c8d7..bf9ffec 100644 --- a/recipes/telegram/webview.js +++ b/recipes/telegram/webview.js @@ -1,8 +1,10 @@ // Code copied from: https://gitlab.com/gortega4/ferdi_recipes -const path = require('path'); +const _path = _interopRequireDefault(require('path')); -module.exports = Franz => { +function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + +module.exports = Ferdi => { const getMessages = function getMessages() { let count = 0; let count_sec = 0; @@ -21,9 +23,10 @@ module.exports = Franz => { } } - Franz.setBadge(count, count_sec); + Ferdi.setBadge(count, count_sec); }; - Franz.injectCSS(path.join(__dirname, 'service.css')); - Franz.loop(getMessages); + Ferdi.loop(getMessages); + + Ferdi.injectCSS(_path.default.join(__dirname, 'service.css')); }; -- cgit v1.2.3-70-g09d2