import 'dart:typed_data'; import 'package:flutter/services.dart'; const utils = const MethodChannel('com.cake_wallet/native_utils'); Future secRandom(int count) async { try { return await utils.invokeMethod('sec_random', {'count': count}); } on PlatformException catch (_) { return Uint8List.fromList([]); } }