chore: dart 3+

This commit is contained in:
lollipopkit
2023-10-28 21:52:18 +08:00
parent 7de5987355
commit 1023f092f6
4 changed files with 4 additions and 6 deletions

View File

@@ -133,9 +133,7 @@ class AppUpdatePlatformSpecific<T> {
return linux;
/// Not implemented yet.
case OS.web:
case OS.fuchsia:
case OS.unknown:
case OS.web || OS.fuchsia || OS.unknown:
return null;
}
}

View File

@@ -325,7 +325,7 @@ class ServerProvider extends ChangeNotifier {
Loggers.app.warning('Write script to ${spi.name} failed', e);
return;
} finally {
await file.delete();
if (await file.exists()) await file.delete();
}
}
}