Add permission check when creating PR#31033
Conversation
|
Some tests using organization user as the PR poster.....It will take lots of time to fix them. 😕 |
|
@Zettat123 |
My fault. It should be converted to an non-org user. |
He should be a collaborator of the base repository if he creates a PR from the same repository. |
This is not the Github's logic, Github's logic is checking base repo, not head repo (for public repos) |
|
See: yp05327/test#7 yp05328 is a collaborator of |
|
Conflict fixed. |
|
I was unable to create a backport for 1.22. @yp05327, please send one manually. 🍵 |
user should be a collaborator of the base repo to create a PR
* giteaofficial/main: Set owner id to zero when GetRegistrationToken for repo (go-gitea#31725) fix(api): owner ID should be zero when created repo secret (go-gitea#31715) Fix API endpoint for registration-token (go-gitea#31722) Fix loadRepository error when access user dashboard (go-gitea#31719) Add permission check when creating PR (go-gitea#31033)

user should be a collaborator of the base repo to create a PR