mirror of
https://github.com/zulip/zulip-desktop.git
synced 2025-11-16 11:51:36 +00:00
Fix unread count parsing from page title.
Fixes #1157 Signed-off-by: Anders Kaseorg <anders@zulip.com>
This commit is contained in:
@@ -184,7 +184,7 @@ export default class WebView {
|
|||||||
}
|
}
|
||||||
|
|
||||||
getBadgeCount(title: string): number {
|
getBadgeCount(title: string): number {
|
||||||
const messageCountInTitle = /\((\d+)\)/.exec(title);
|
const messageCountInTitle = /^\((\d+)\)/.exec(title);
|
||||||
return messageCountInTitle ? Number(messageCountInTitle[1]) : 0;
|
return messageCountInTitle ? Number(messageCountInTitle[1]) : 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user