diff options
Diffstat (limited to 'recipes/nextcloud-news/webview.js')
-rw-r--r-- | recipes/nextcloud-news/webview.js | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/recipes/nextcloud-news/webview.js b/recipes/nextcloud-news/webview.js index 048ac7d..7c1c65c 100644 --- a/recipes/nextcloud-news/webview.js +++ b/recipes/nextcloud-news/webview.js | |||
@@ -1,13 +1,15 @@ | |||
1 | const _path = _interopRequireDefault(require('path')); | 1 | const _path = _interopRequireDefault(require('path')); |
2 | 2 | ||
3 | function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } | 3 | function _interopRequireDefault(obj) { |
4 | return obj && obj.__esModule ? obj : { default: obj }; | ||
5 | } | ||
4 | 6 | ||
5 | module.exports = Ferdi => { | 7 | module.exports = Ferdi => { |
6 | const getMessages = () => { | 8 | const getMessages = () => { |
7 | const selector = document.querySelector( | 9 | const selector = document.querySelector( |
8 | '.subscriptions-feed .app-navigation-entry-utils-counter', | 10 | '.subscriptions-feed .app-navigation-entry-utils-counter', |
9 | ); | 11 | ); |
10 | const direct = selector ? Ferdi.safeParseInt(selector.innerText) : 0; | 12 | const direct = selector ? Ferdi.safeParseInt(selector.textContent) : 0; |
11 | 13 | ||
12 | Ferdi.setBadge(direct); | 14 | Ferdi.setBadge(direct); |
13 | }; | 15 | }; |