I have a function that should have three required and in best case named parameters. The last one ("finished") should be optional. I tried it like this:
static void showOverlay(BuildContext context, String text, bool successfull,
[VoidCallback? finished]) {}
but Flutter is complaining:
Avoid positional boolean parameters
The weird thing is that it is only complaining about the bool successfull. What am I doing wrong here and how can I fix this?