I have a proplem in assigning a sign in future method to onpressed :The argument type 'Future' can't be assigned to the parameter type 'void Function()'.
you have to assign it like this:
onpressed: () => FunctionName()
Because the handler expects a function with no return. So we just call your function inside an anonymous void function.