private async Task OnCheckForUpdatesExecute() { AvailableUpdates.Clear(); var packages = await TaskHelper.Run(() => _packagesUpdatesSearcherService.SearchForUpdates(AllowPrerelease, false), true); // TODO: AddRange doesn't refresh button state. need to fix later AvailableUpdates = new ObservableCollection <IPackageDetails>(packages); }
private async Task OnCheckForUpdatesExecute() { if (AvailableUpdates == null) { return; } AvailableUpdates.Clear(); using (_pleaseWaitService.WaitingScope()) { var packages = await TaskHelper.Run(() => _packagesUpdatesSearcherService.SearchForUpdates(), true); // TODO: AddRange doesn't refresh button state. need to fix later AvailableUpdates = new ObservableCollection <IPackageDetails>(packages); } await OnOpenUpdateWindowExecuteAsync(); }