Browse Source

Improved regex for detect new messages

pull/17/head 0.2.4
Ramiro Saenz 9 years ago
parent
commit
f941807db8
  1. 3
      app/ux/WebView.js

3
app/ux/WebView.js

@ -108,8 +108,9 @@ Ext.define('Rambox.ux.WebView',{
});
webview.addEventListener("page-title-updated", function(e) {
var count = e.title.match(/\((\d+)\)/);
var count = e.title.match(/\(([^)]+)\)/);
count = count ? parseInt(count[1]) : 0;
count = Ext.isNaN(count) ? 0 : count; // Some services have special characters. Example: (•)
switch ( me.type ) {
case 'messenger':

Loading…
Cancel
Save