-
-
Notifications
You must be signed in to change notification settings - Fork 5.6k
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
Admin should not delete himself #19423
Conversation
However, it doesn't resolve the issue fundamentally. IIRC the issue author meant that he did the dumb operation by setting himself as non-admin. And beside such operation, there could be more situations that the only admin can do dumb operations to get stuck:
|
I agree with 1...3, |
I think we should add a check if CurrentUser is the only admin left ... |
I think this is more enhancement than bug so I'm not sure that this should be backported. |
3930b63
to
b5facd0
Compare
It's ready. |
make lgtm work |
* giteaofficial/main: [skip ci] Updated translations via Crowdin Calculate filename hash only once (go-gitea#19654) Admin should not delete himself (go-gitea#19423) Restore reviewed-on message (go-gitea#19657) Move some helper files out of models (go-gitea#19355) Repository level enable package or disable (go-gitea#19323)
Admin should not be able to delete themselves. Also partially fix go-gitea#15449
Also partially fix #15449