Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix bug on branch API #10767

Merged
merged 1 commit into from Mar 19, 2020
Merged

Fix bug on branch API #10767

merged 1 commit into from Mar 19, 2020

Conversation

@lunny
Copy link
Member

lunny commented Mar 19, 2020

Fix #10738. When request the API with a non-login user, you cannot use user.ID so that it will panic. This PR let canpush and canmerge as false if not login.

@lunny lunny added this to the 1.12.0 milestone Mar 19, 2020
@GiteaBot GiteaBot added lgtm/done and removed lgtm/need 1 labels Mar 19, 2020
@techknowlogick techknowlogick merged commit 83fe7d4 into go-gitea:master Mar 19, 2020
2 checks passed
2 checks passed
approvals/lgtm this commit looks good
continuous-integration/drone/pr Build is passing
Details
@techknowlogick

This comment has been minimized.

Copy link
Member

techknowlogick commented Mar 19, 2020

@lunny please backport :)

@lunny lunny deleted the lunny:lunny/fix_branch_api branch Mar 19, 2020
lunny added a commit to lunny/gitea that referenced this pull request Mar 20, 2020
@lunny lunny added the backport/done label Mar 20, 2020
lafriks pushed a commit that referenced this pull request Mar 20, 2020
* Fix bug on branch API (#10767)

* Fix branch api canPush and canMerge
everhopingandwaiting added a commit to everhopingandwaiting/gitea that referenced this pull request Apr 4, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Linked issues

Successfully merging this pull request may close these issues.

4 participants
You can’t perform that action at this time.