Fetch base branch after merging pull request

This commit is contained in:
Mattias Granlund 2024-02-05 13:54:30 +01:00
parent ecd37a38a8
commit d3aca530fa

View File

@ -55,7 +55,10 @@ export class GitHubService {
private enabled = false; private enabled = false;
constructor(userService: UserService, baseBranchService: BaseBranchService) { constructor(
userService: UserService,
private baseBranchService: BaseBranchService
) {
// A few things will cause the baseBranch to update, so we filter for distinct // A few things will cause the baseBranch to update, so we filter for distinct
// changes to the remoteUrl. // changes to the remoteUrl.
const distinctUrl$ = baseBranchService.base$.pipe(distinct((ctx) => ctx?.remoteUrl)); const distinctUrl$ = baseBranchService.base$.pipe(distinct((ctx) => ctx?.remoteUrl));
@ -286,6 +289,7 @@ export class GitHubService {
pull_number: pullNumber, pull_number: pullNumber,
merge_method: method merge_method: method
}); });
await this.baseBranchService.fetchFromTarget();
} finally { } finally {
this.reload(); this.reload();
} }