shorebird cleanup

This commit is contained in:
Jonas Bark
2026-02-16 11:02:59 +01:00
parent ad7bd646f3
commit ab379cf74b

View File

@@ -94,10 +94,20 @@ class _AppTitleState extends State<AppTitle> with WidgetsBindingObserver {
if (updateStatus == UpdateStatus.outdated) {
updater
.update()
.then((value) {
.then((value) async {
setState(() {
_updateType = UpdateType.shorebird;
});
final nextPatch = await updater.readNextPatch();
final currentVersion = Version.parse(packageInfoValue!.version);
setState(() {
_newVersion = Version(
currentVersion.major,
currentVersion.minor,
currentVersion.patch,
build: nextPatch?.number.toString() ?? '',
);
});
})
.catchError((e) {
buildToast(title: AppLocalizations.current.failedToUpdate(e.toString()));