mirror of
https://github.com/flutter/samples.git
synced 2025-11-11 07:18:15 +00:00
[platform_channels] Migrate to sound null safety (#803)
This commit is contained in:
@@ -15,7 +15,7 @@ class PlatformImageFetcher {
|
||||
|
||||
/// Method responsible for providing the platform image.
|
||||
static Future<Uint8List> getImage() async {
|
||||
final reply = await _basicMessageChannel.send('getImage') as Uint8List;
|
||||
final reply = await _basicMessageChannel.send('getImage') as Uint8List?;
|
||||
if (reply == null) {
|
||||
throw PlatformException(
|
||||
code: 'Error',
|
||||
|
||||
Reference in New Issue
Block a user