[mob][photos] Chore

This commit is contained in:
ashilkn
2024-08-10 16:42:54 +05:30
parent c27017e77e
commit 1aa38253a3
15 changed files with 27 additions and 28 deletions

View File

@@ -121,12 +121,12 @@ class _ToggleSwitchWidgetState extends State<ToggleSwitchWidget> {
});
final Stopwatch stopwatch = Stopwatch()..start();
await widget.onChanged.call().onError(
(error, stackTrace) => _debouncer.cancelDebounce(),
(error, stackTrace) => _debouncer.cancelDebounceTimer(),
);
//for toggle feedback on short unsuccessful onChanged
await _feedbackOnUnsuccessfulToggle(stopwatch);
//debouncer gets canceled if onChanged takes less than debounce time
_debouncer.cancelDebounce();
_debouncer.cancelDebounceTimer();
final newValue = widget.value.call();
setState(() {