Closed MoshDev closed 4 years ago
static Future<String> _createTmpFilePath() async { final cacheDir = await NativeChannel.getCachePath(); final name = DateTime.now().millisecondsSinceEpoch; return "$cacheDir/$name"; }
"$cacheDir/$name" = "Directory: '/data/user/0/com.sample.debug/cache'1577749314116"
your NativeChannel.getCachePath(); returns Directory instance not a String
solution return "${cacheDir.path}/$name";
return "${cacheDir.path}/$name";
"$cacheDir/$name" = "Directory: '/data/user/0/com.sample.debug/cache'1577749314116"
your NativeChannel.getCachePath(); returns Directory instance not a String
solution
return "${cacheDir.path}/$name";