'The argument type 'SomeType?' can't be assigned to the parameter type 'SomeType'

I get an error when trying to call a function:

The argument type 'SomeType?' can't be assigned to the parameter type 'SomeType'

How do I fix this?



Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source