Skip to content

Commit

Permalink
fixup! fixup! fixup! TW-1862: Fix can't display message in chat
Browse files Browse the repository at this point in the history
  • Loading branch information
nqhhdev committed Dec 10, 2024
1 parent 14fd132 commit 557d2e8
Showing 1 changed file with 7 additions and 5 deletions.
12 changes: 7 additions & 5 deletions lib/pages/chat/chat.dart
Original file line number Diff line number Diff line change
Expand Up @@ -1734,6 +1734,12 @@ class ChatController extends State<Chat>
_currentChatScrollState = ChatScrollState.scrolling;
}

List<String> get getEventTypeToFilterUnnecessaryEvent => [
EventTypes.Message,
EventTypes.Encrypted,
EventTypes.Sticker,
];

Future<void> _tryRequestHistory() async {
if (timeline == null) return;

Expand All @@ -1759,11 +1765,7 @@ class ChatController extends State<Chat>
historyCount: _defaultEventCountDisplay,
filter: StateFilter(
lazyLoadMembers: true,
types: [
EventTypes.Message,
EventTypes.Encrypted,
EventTypes.Sticker,
],
types: getEventTypeToFilterUnnecessaryEvent,
),
);
}
Expand Down

0 comments on commit 557d2e8

Please sign in to comment.