I'm rather new to programming in Dart but I noticed that when I run the example I get an error along the lines of "Expected a value of type 'Object', but got one of type 'Null'".
I appear to have narrowed the issue down to not accounting for null safety (https://dart.dev/null-safety/understanding-null-safety). However I don't quite know how to rewrite the example just yet so I can't commit a direct change.
I'm rather new to programming in Dart but I noticed that when I run the example I get an error along the lines of "Expected a value of type 'Object', but got one of type 'Null'".
I appear to have narrowed the issue down to not accounting for null safety (https://dart.dev/null-safety/understanding-null-safety). However I don't quite know how to rewrite the example just yet so I can't commit a direct change.