Skip to content
Snippets Groups Projects
Commit e2cd419b authored by Jan-Christoph Borchardt's avatar Jan-Christoph Borchardt
Browse files

fix title double dash for unified inbox, ref #803

parent 140c7059
No related branches found
No related tags found
No related merge requests found
......@@ -111,17 +111,21 @@ views.Folders = Backbone.Marionette.CollectionView.extend({
},
updateTitle: function() {
var activeAccount = Mail.State.currentAccountId;
activeAccount = this.collection.get(activeAccount);
var activeEmail = '';
if (Mail.State.currentAccountId !== -1) {
var activeAccount = Mail.State.currentAccountId;
activeAccount = this.collection.get(activeAccount);
activeEmail = ' - ' + activeAccount.get('email');
}
var activeFolder = this.getFolderById();
var unread = activeFolder.unseen;
var name = activeFolder.name || activeFolder.get('name');
if (unread > 0) {
window.document.title = name + ' (' + unread + ') - ' +
activeAccount.get('email') + ' - Mail - ' + oc_defaults.title;
window.document.title = name + ' (' + unread + ')' +
activeEmail + ' - Mail - ' + oc_defaults.title;
} else {
window.document.title = name + ' - ' + activeAccount.get('email') +
window.document.title = name + activeEmail +
' - Mail - ' + oc_defaults.title;
}
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment