Fix "Switch to buffer with activity" skipping buffers with notifications
This caused two buffer switches in a row, in effect forgetting the notifications
This commit is contained in:
parent
f10e44efe4
commit
d4a5218922
1 changed files with 2 additions and 2 deletions
|
@ -832,7 +832,7 @@ weechat.controller('WeechatCtrl', ['$rootScope', '$scope', '$store', '$timeout',
|
||||||
buffer = sortedBuffers[i];
|
buffer = sortedBuffers[i];
|
||||||
if (buffer.notification > 0) {
|
if (buffer.notification > 0) {
|
||||||
$scope.setActiveBuffer(buffer.id);
|
$scope.setActiveBuffer(buffer.id);
|
||||||
break;
|
return; // return instead of break so that the second for loop isn't executed
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
// No notifications, find first buffer with unread lines instead
|
// No notifications, find first buffer with unread lines instead
|
||||||
|
@ -840,7 +840,7 @@ weechat.controller('WeechatCtrl', ['$rootScope', '$scope', '$store', '$timeout',
|
||||||
buffer = sortedBuffers[i];
|
buffer = sortedBuffers[i];
|
||||||
if (buffer.unread > 0) {
|
if (buffer.unread > 0) {
|
||||||
$scope.setActiveBuffer(buffer.id);
|
$scope.setActiveBuffer(buffer.id);
|
||||||
break;
|
return;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
Loading…
Reference in a new issue