remove assert for nullable constructor params

This commit is contained in:
Neevash Ramdial
2021-04-20 10:35:40 +02:00
committed by Salvatore Giordano
parent 74fb9d8dd8
commit e2fed83946
3 changed files with 3 additions and 15 deletions
@@ -25,8 +25,7 @@ class ChannelsBloc extends StatefulWidget {
this.lockChannelsOrder = false,
this.channelsComparator,
this.shouldAddChannel,
}) : assert(child != null, 'Parameter child should not be null.'),
super(key: key);
}) : super(key: key);
/// The widget child
final Widget child;
@@ -70,17 +70,7 @@ class MessageListCore extends StatefulWidget {
this.parentMessage,
this.messageListController,
this.messageFilter,
}) : assert(loadingBuilder != null, 'loadingBuilder should not be null'),
assert(emptyBuilder != null, 'emptyBuilder should not be null'),
assert(
messageListBuilder != null,
'messageListBuilder should not be null',
),
assert(
errorWidgetBuilder != null,
'errorWidgetBuilder should not be null',
),
super(key: key);
}) : super(key: key);
/// A [MessageListController] allows pagination.
/// Use [ChannelListController.paginateData] pagination.
@@ -15,8 +15,7 @@ class MessageSearchBloc extends StatefulWidget {
const MessageSearchBloc({
Key? key,
required this.child,
}) : assert(child != null, 'Parameter child should not be null.'),
super(key: key);
}) : super(key: key);
/// The widget child
final Widget child;