mraible commented on code in PR #334:
URL: https://github.com/apache/roller/pull/334#discussion_r4609094492
##########
app/src/main/java/org/apache/roller/weblogger/ui/struts2/editor/MemberResign.java:
##########
@@ -67,6 +67,10 @@ public String execute() {
public String resign() {
try {
UserManager umgr =
WebloggerFactory.getWeblogger().getUserManager();
+ if (isLastAdmin(umgr)) {
Review Comment:
Resigning and the Members page now share one
UserManager.updateWeblogMembership() operation that locks the weblog's row,
re-reads its memberships, refuses changes that would leave no enabled
administrator, and applies them in the same transaction. WeblogMembershipTest
covers the operation, Members.save, and two administrators resigning at the
same moment, which let both resign before the change and now leaves exactly one.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]