File tree Expand file tree Collapse file tree 3 files changed +4
-4
lines changed Expand file tree Collapse file tree 3 files changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -21,8 +21,8 @@ class TypingStatus extends PerAccountStoreBase with ChangeNotifier {
21
21
22
22
Iterable <SendableNarrow > get debugActiveNarrows => _timerMapsByNarrow.keys;
23
23
24
- Iterable <int > typistIdsInNarrow (SendableNarrow narrow) =>
25
- _timerMapsByNarrow[narrow]? .keys ?? [] ;
24
+ Iterable <int >? typistIdsInNarrow (SendableNarrow narrow) =>
25
+ _timerMapsByNarrow[narrow]? .keys;
26
26
27
27
// Using SendableNarrow as the key covers the narrows
28
28
// where typing notices are supported (topics and DMs).
Original file line number Diff line number Diff line change @@ -946,7 +946,7 @@ class _TypingStatusWidgetState extends State<TypingStatusWidget> with PerAccount
946
946
final store = PerAccountStoreWidget .of (context);
947
947
final zulipLocalizations = ZulipLocalizations .of (context);
948
948
final typistIds = model! .typistIdsInNarrow (narrow);
949
- if (typistIds.isEmpty ) return const SizedBox ();
949
+ if (typistIds == null ) return const SizedBox ();
950
950
final text = switch (typistIds.length) {
951
951
1 => zulipLocalizations.onePersonTyping (
952
952
store.userDisplayName (typistIds.first)),
Original file line number Diff line number Diff line change @@ -65,7 +65,7 @@ void main() {
65
65
}
66
66
67
67
void checkTypists (Map <SendableNarrow , List <User >> typistsByNarrow) {
68
- final actualTypistsByNarrow = < SendableNarrow , Iterable <int >> {};
68
+ final actualTypistsByNarrow = < SendableNarrow , Iterable <int >? > {};
69
69
for (final narrow in model.debugActiveNarrows) {
70
70
actualTypistsByNarrow[narrow] = model.typistIdsInNarrow (narrow);
71
71
}
You can’t perform that action at this time.
0 commit comments