We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 1ad57af commit 598b498Copy full SHA for 598b498
console/src/tasks.rs
@@ -242,6 +242,11 @@ impl State {
242
}
243
244
pub(crate) fn retain_active(&mut self) {
245
+ // Don't clean up stopped tasks while the console is paused.
246
+ if self.is_paused() {
247
+ return;
248
+ }
249
+
250
self.tasks.retain(|_, task| {
251
let mut task = task.borrow_mut();
252
if task.completed_for == 0 {
@@ -455,7 +460,6 @@ impl Default for SortBy {
455
460
456
461
impl SortBy {
457
462
pub fn sort(&self, now: SystemTime, tasks: &mut Vec<Weak<RefCell<Task>>>) {
458
- // tasks.retain(|t| t.upgrade().is_some());
459
463
match self {
464
Self::Tid => tasks.sort_unstable_by_key(|task| task.upgrade().map(|t| t.borrow().id)),
465
Self::Name => {
0 commit comments