From f74ec45ca6fbc3c9705bf29848ede2a19cf7ef7a Mon Sep 17 00:00:00 2001 From: Flaminel Date: Sat, 21 Mar 2026 21:49:10 +0200 Subject: [PATCH] improved toggle reset in toggleRoundRobin --- .../src/app/features/settings/seeker/seeker.component.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/code/frontend/src/app/features/settings/seeker/seeker.component.ts b/code/frontend/src/app/features/settings/seeker/seeker.component.ts index 1c855327..ad6d1506 100644 --- a/code/frontend/src/app/features/settings/seeker/seeker.component.ts +++ b/code/frontend/src/app/features/settings/seeker/seeker.component.ts @@ -158,10 +158,10 @@ export class SeekerComponent implements OnInit, HasPendingChanges { }); if (!confirmed) { // The toggle already flipped its internal state to false. - // Sync our signal to false first, then restore to true in the next tick + // Sync our signal to false first, then restore to true in the next microtask // so Angular detects an actual change and pushes it back to the toggle. this.useRoundRobin.set(false); - setTimeout(() => this.useRoundRobin.set(true)); + queueMicrotask(() => this.useRoundRobin.set(true)); return; } }