fix lag on saving frozen coin status (#3164)

* fix lag on saving frozen coin status

* wrap saveUnspentCoinInfo in @action

* revert fix + safeguard coin control page
This commit is contained in:
malik1004x
2026-04-15 14:31:44 +02:00
committed by GitHub
parent 586a040e4a
commit fb14d07fc7
4 changed files with 35 additions and 11 deletions
@@ -116,6 +116,7 @@ abstract class UnspentCoinsListViewModelBase with Store {
bool get hasAdjustableFieldChanged => items.any(_hasAdjustableFieldChanged);
@action
Future<void> saveUnspentCoinInfo(UnspentCoinsItem item) async {
try {
item.isBeingSaved = true;
@@ -129,8 +130,6 @@ abstract class UnspentCoinsListViewModelBase with Store {
existingInfo.note = item.note;
await existingInfo.save();
await _updateUnspents();
await wallet.updateBalance();
item.isBeingSaved = false;
isSavingItems = false;
} catch (e) {