Skip to content

Commit

Permalink
Fix: update logs when device or level filters change
Browse files Browse the repository at this point in the history
  • Loading branch information
Levi-Lesches committed Oct 30, 2024
1 parent d182931 commit e4e15d3
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions lib/src/models/view/logs.dart
Original file line number Diff line number Diff line change
Expand Up @@ -135,6 +135,7 @@ class LogsViewModel with ChangeNotifier {

/// Listens for incoming logs.
LogsViewModel() {
options.addListener(notifyListeners);
scrollController = ScrollController(
onAttach: _listenForScroll,
onDetach: _stopListeningForScroll,
Expand All @@ -146,6 +147,8 @@ class LogsViewModel with ChangeNotifier {

@override
void dispose() {
options.removeListener(notifyListeners);
options.dispose();
models.logs.removeListener(onNewLog);
super.dispose();
}
Expand Down

0 comments on commit e4e15d3

Please sign in to comment.