diff options
Diffstat (limited to 'recipes/google-groups')
-rw-r--r-- | recipes/google-groups/package.json | 2 | ||||
-rw-r--r-- | recipes/google-groups/webview.js | 8 |
2 files changed, 6 insertions, 4 deletions
diff --git a/recipes/google-groups/package.json b/recipes/google-groups/package.json index f1ff58d..38c3470 100644 --- a/recipes/google-groups/package.json +++ b/recipes/google-groups/package.json | |||
@@ -1,7 +1,7 @@ | |||
1 | { | 1 | { |
2 | "id": "google-groups", | 2 | "id": "google-groups", |
3 | "name": "Google Groups", | 3 | "name": "Google Groups", |
4 | "version": "1.0.1", | 4 | "version": "1.1.0", |
5 | "license": "MIT", | 5 | "license": "MIT", |
6 | "config": { | 6 | "config": { |
7 | "serviceURL": "https://groups.google.com/u/0/" | 7 | "serviceURL": "https://groups.google.com/u/0/" |
diff --git a/recipes/google-groups/webview.js b/recipes/google-groups/webview.js index 7006eef..c13334a 100644 --- a/recipes/google-groups/webview.js +++ b/recipes/google-groups/webview.js | |||
@@ -1,15 +1,17 @@ | |||
1 | const _path = _interopRequireDefault(require('path')); | ||
2 | |||
3 | function _interopRequireDefault(obj) { | 1 | function _interopRequireDefault(obj) { |
4 | return obj && obj.__esModule ? obj : { default: obj }; | 2 | return obj && obj.__esModule ? obj : { default: obj }; |
5 | } | 3 | } |
6 | 4 | ||
5 | const _path = _interopRequireDefault(require('path')); | ||
6 | |||
7 | module.exports = Ferdium => { | 7 | module.exports = Ferdium => { |
8 | const getMessages = () => { | 8 | const getMessages = () => { |
9 | let countImportant = 0; | 9 | let countImportant = 0; |
10 | const unReadConversationCount = document.querySelectorAll('.NHlkZc'); | 10 | const unReadConversationCount = document.querySelectorAll('.NHlkZc'); |
11 | if (unReadConversationCount.length > 0) { | 11 | if (unReadConversationCount.length > 0) { |
12 | countImportant = Ferdium.safeParseInt(unReadConversationCount[0].textContent); | 12 | countImportant = Ferdium.safeParseInt( |
13 | unReadConversationCount[0].textContent, | ||
14 | ); | ||
13 | } | 15 | } |
14 | Ferdium.setBadge(countImportant, 0); | 16 | Ferdium.setBadge(countImportant, 0); |
15 | }; | 17 | }; |