mirror of
https://gitlab.com/comunic/comunicmobile
synced 2025-06-21 01:05:18 +00:00
Fix a few notices
This commit is contained in:
@ -246,9 +246,7 @@ class _ResetPasswordBodyState extends SafeState<_ResetPasswordBody> {
|
||||
class _Spacer extends StatelessWidget {
|
||||
final bool visible;
|
||||
|
||||
const _Spacer({Key? key, this.visible = true})
|
||||
: assert(visible != null),
|
||||
super(key: key);
|
||||
const _Spacer({Key? key, this.visible = true}) : super(key: key);
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
|
@ -50,8 +50,9 @@ abstract class MainController extends State<MainRoute> {
|
||||
int get numberOfPages => _pagesStack.length;
|
||||
|
||||
/// Get current instance of Home controller
|
||||
///
|
||||
/// A future implementation might need context again, that is why it is required
|
||||
static MainController? of(BuildContext context) {
|
||||
assert(context != null); // A future implementation might need context again
|
||||
return mainControllerKey.currentState;
|
||||
}
|
||||
|
||||
|
@ -126,7 +126,7 @@ class PushNotificationsConfigurationWidgetState
|
||||
available: srvConfig!.notificationsPolicy.hasFirebase,
|
||||
onChanged: (s) {
|
||||
setState(() => currStatus = s);
|
||||
if (widget.onChanged != null) widget.onChanged();
|
||||
widget.onChanged();
|
||||
},
|
||||
),
|
||||
SizedBox(height: 5),
|
||||
|
@ -129,8 +129,7 @@ class _NewCustomEmojiDialog extends StatefulWidget {
|
||||
const _NewCustomEmojiDialog({
|
||||
Key? key,
|
||||
required this.currentList,
|
||||
}) : assert(currentList != null),
|
||||
super(key: key);
|
||||
}) : super(key: key);
|
||||
|
||||
@override
|
||||
_NewCustomEmojiDialogState createState() => _NewCustomEmojiDialogState();
|
||||
|
Reference in New Issue
Block a user