remove method

Future<void> remove(
  1. String path, {
  2. bool useMemory = false,
  3. bool nowWrite = true,
  4. bool isFailTip = true,
})

Implementation

Future<void> remove(
  String path, {
  bool useMemory = false,
  bool nowWrite = true,
  bool isFailTip = true,
}) async {
  final AssetItem? asset = list.remove(path);
  if (asset == null) return;

  await Future.wait([
    asset.remove(
      useMemory: useMemory,
      isFailTip: isFailTip,
    ),
    if (nowWrite) writeListFile(),
  ]);
}