chore(repo): fix lints

Signed-off-by: xsahil03x <[email protected]>
This commit is contained in:
Sahil Kumar
2021-10-01 16:45:16 +05:30
committed by xsahil03x
parent 6e48f9754d
commit ca7cf541a7
76 changed files with 1004 additions and 969 deletions
@@ -94,6 +94,7 @@ class _BetterStreamBuilderState<T extends Object>
if (widget.errorBuilder != null && error != _lastError) {
_lastError = error;
if (mounted) {
// ignore: no-empty-block
setState(() {});
}
}
@@ -106,7 +107,7 @@ class _BetterStreamBuilderState<T extends Object>
if (!isEqual) {
_lastEvent = event;
if (mounted) {
setState(() {});
setState(() {}); // ignore: no-empty-block
}
}
}
@@ -111,8 +111,7 @@ class ChannelsBlocState extends State<ChannelsBloc>
_paginationEnded = false;
}
if ((!clear && _paginationEnded) ||
_queryChannelsLoadingController.value == true) {
if ((!clear && _paginationEnded) || _queryChannelsLoadingController.value) {
return;
}
@@ -221,7 +220,8 @@ class ChannelsBlocState extends State<ChannelsBloc>
.listen((e) {
final channel = e.channel;
_channelsController.add(List.from(
(channels ?? [])..removeWhere((c) => c.cid == channel?.cid)));
(channels ?? [])..removeWhere((c) => c.cid == channel?.cid),
));
}));
}
@@ -88,7 +88,7 @@ class StreamChannelState extends State<StreamChannel> {
bool preferOffline = false,
}) async {
if (_topPaginationEnded ||
_queryTopMessagesController.value == true ||
_queryTopMessagesController.value ||
channel.state == null) {
return;
}
@@ -120,9 +120,9 @@ class StreamChannelState extends State<StreamChannel> {
bool preferOffline = false,
}) async {
if (_bottomPaginationEnded ||
_queryBottomMessagesController.value == true ||
_queryBottomMessagesController.value ||
channel.state == null ||
channel.state!.isUpToDate == true) return;
channel.state!.isUpToDate) return;
_queryBottomMessagesController.add(true);
if (channel.state!.messages.isEmpty) {
@@ -164,7 +164,7 @@ class StreamChannelState extends State<StreamChannel> {
bool preferOffline = false,
}) async {
if (_topPaginationEnded ||
_queryTopMessagesController.value == true ||
_queryTopMessagesController.value ||
channel.state == null) return;
_queryTopMessagesController.add(true);
@@ -19,7 +19,7 @@ dependencies:
stream_chat: ^3.0.0
dev_dependencies:
dart_code_metrics: ^4.2.0-dev.1
dart_code_metrics: ^4.2.0-dev.5
fake_async: ^1.2.0
flutter_test:
sdk: flutter