optimizations

This commit is contained in:
mertalev
2025-07-30 19:30:42 -04:00
parent 196f2a72f4
commit 6cea779b2d
23 changed files with 7004 additions and 329 deletions
+3 -2
View File
@@ -27,8 +27,9 @@ class Debouncer {
}
Future<void>? drain() {
if (_timer != null && _timer!.isActive) {
_timer!.cancel();
final timer = _timer;
if (timer != null && timer.isActive) {
timer.cancel();
if (_lastAction != null) {
_callAndRest();
}