2
2
mirror of https://github.com/Llewellynvdm/nativefier.git synced 2024-12-23 02:28:55 +00:00

Make title counter regex match '+' after number, used by certain sites (#424)

This commit is contained in:
Lukas Kurucz 2017-08-14 09:22:15 +08:00 committed by Ronan Jouchet
parent b5913b086e
commit 094cac23bc

View File

@ -171,7 +171,7 @@ function createMainWindow(inpOptions, onAppQuit, setDockBadge) {
if (options.counter) {
mainWindow.on('page-title-updated', (e, title) => {
const itemCountRegex = /[([{](\d*?)[}\])]/;
const itemCountRegex = /[([{](\d*?)\+?[}\])]/;
const match = itemCountRegex.exec(title);
if (match) {
setDockBadge(match[1]);