gitea/services/pull
Lunny Xiao b9efbe9fe6
Fix push commits comments when changing the pull request target branch (#35386)
When changing the pull request target branch, the pushed commits
comments will not be changed resulted the number are inconsistent
between commits tab number and the pushed commits comments number.

This PR will remove all the previous pushed commits comments and
calculate new comments when changing the target branch.

Before:

<img width="928" height="585" alt="image"
src="https://github.com/user-attachments/assets/35e4d31f-31a1-4d14-83b0-1786721ab0d9"
/>

After:
<img width="816" height="623" alt="image"
src="https://github.com/user-attachments/assets/24b6dafe-9238-4e7e-833d-68472457afab"
/>
2025-09-09 19:40:54 +00:00
..
check.go Rename pull request GetGitRefName to GetGitHeadRefName (#35093) 2025-07-16 21:33:33 +08:00
check_test.go Remove incorrect "db.DefaultContext" usages (#35366) 2025-08-28 03:52:43 +00:00
comment.go Fix push commits comments when changing the pull request target branch (#35386) 2025-09-09 19:40:54 +00:00
commit_status.go Rename pull request GetGitRefName to GetGitHeadRefName (#35093) 2025-07-16 21:33:33 +08:00
commit_status_test.go Fix required contexts and commit status matching bug (#34815) 2025-06-22 23:31:46 +00:00
compare.go Move git config/remote to gitrepo package and add global lock to resolve possible conflict when updating repository git config file (#35151) 2025-09-01 18:47:04 +00:00
edits.go Implement FSFE REUSE for golang files (#21840) 2022-11-27 18:20:29 +00:00
lfs.go Remove incorrect "db.DefaultContext" usages (#35366) 2025-08-28 03:52:43 +00:00
main_test.go make writing main test easier (#27270) 2023-09-28 01:38:53 +00:00
merge.go Use db.WithTx/WithTx2 instead of TxContext when possible (#35130) 2025-07-22 10:02:01 -07:00
merge_ff_only.go Remove context from git struct (#33793) 2025-03-04 11:56:11 -08:00
merge_merge.go Remove context from git struct (#33793) 2025-03-04 11:56:11 -08:00
merge_prepare.go Improve instance wide ssh commit signing (#34341) 2025-06-11 10:32:55 +00:00
merge_rebase.go Remove context from git struct (#33793) 2025-03-04 11:56:11 -08:00
merge_squash.go Improve instance wide ssh commit signing (#34341) 2025-06-11 10:32:55 +00:00
merge_test.go Always use an empty line to separate the commit message and trailer (#34512) 2025-06-02 06:29:16 +00:00
patch.go Rename pull request GetGitRefName to GetGitHeadRefName (#35093) 2025-07-16 21:33:33 +08:00
patch_unmerged.go Remove context from git struct (#33793) 2025-03-04 11:56:11 -08:00
protected_branch.go Move git references checking to gitrepo packages to reduce expose of repository path (#33891) 2025-03-15 19:48:59 -07:00
pull.go Fix push commits comments when changing the pull request target branch (#35386) 2025-09-09 19:40:54 +00:00
pull_test.go Remove incorrect "db.DefaultContext" usages (#35366) 2025-08-28 03:52:43 +00:00
review.go Rename pull request GetGitRefName to GetGitHeadRefName (#35093) 2025-07-16 21:33:33 +08:00
review_test.go Remove incorrect "db.DefaultContext" usages (#35366) 2025-08-28 03:52:43 +00:00
reviewer.go Fix team permissions (#34827) 2025-06-24 21:24:09 +08:00
reviewer_test.go Remove incorrect "db.DefaultContext" usages (#35366) 2025-08-28 03:52:43 +00:00
temp_repo.go Rename pull request GetGitRefName to GetGitHeadRefName (#35093) 2025-07-16 21:33:33 +08:00
update.go Fix possible pull request broken when leave the page immediately after clicking the update button (#34509) 2025-06-04 17:09:08 +00:00
update_rebase.go Remove context from git struct (#33793) 2025-03-04 11:56:11 -08:00