Improved ReactiveCommand.CreateFromTask

This commit is contained in:
2dust
2024-10-10 18:02:09 +08:00
parent 4f5362fdc4
commit a556bf9487
14 changed files with 209 additions and 202 deletions

View File

@@ -48,9 +48,9 @@ namespace ServiceLib.ViewModels
IP = Utils.List2String(SelectedSource.ip, true);
Process = Utils.List2String(SelectedSource.process, true);
SaveCmd = ReactiveCommand.Create(() =>
SaveCmd = ReactiveCommand.CreateFromTask(async () =>
{
SaveRulesAsync();
await SaveRulesAsync();
});
}