Skip to content
This repository was archived by the owner on Jun 21, 2023. It is now read-only.

Commit b95d370

Browse files
committed
Update PR details when review submitted.
1 parent 2360038 commit b95d370

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

src/GitHub.App/ViewModels/GitHubPane/PullRequestDetailViewModel.cs

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -53,6 +53,7 @@ public sealed class PullRequestDetailViewModel : PanePageViewModelBase, IPullReq
5353
bool active;
5454
bool refreshOnActivate;
5555
Uri webUrl;
56+
IDisposable sessionSubscription;
5657

5758
/// <summary>
5859
/// Initializes a new instance of the <see cref="PullRequestDetailViewModel"/> class.
@@ -441,6 +442,11 @@ public async Task Load(IPullRequestModel pullRequest)
441442
UpdateState = null;
442443
}
443444

445+
sessionSubscription?.Dispose();
446+
sessionSubscription = Session.WhenAnyValue(x => x.HasPendingReview)
447+
.Skip(1)
448+
.Subscribe(x => Reviews = PullRequestReviewSummaryViewModel.BuildByUser(Session.User, Session.PullRequest).ToList());
449+
444450
if (firstLoad)
445451
{
446452
usageTracker.IncrementCounter(x => x.NumberOfPullRequestsOpened).Forget();

0 commit comments

Comments
 (0)