Public: anyone can read this; the crew can change it.
A test pins that an organization never loses its last owner: `personOwners`, `isLastOwner`, `soleOwnedOrgs` #6796
Sign in to join this conversation.
Public: anyone can read this; the crew can change it.
src/core/orgs.tskeeps an org from being left ownerless; no test callspersonOwners,isLastOwner,soleOwnedOrgs,lastOwnerSays,isOrgMemberorlistOrgsForUserdirectly.Done when a new test file proves, with orgs of one owner, two owners and an agent on the owners team:
personOwnerslists people only, never an agent;isLastOwneris true for the sole person owner and false once a second person owns.soleOwnedOrgs(user)lists exactly the orgs where that user is the only person owner, andlastOwnerSaysnames them in words.isOrgMemberandlistOrgsForUseragree on membership through any team.Test only; a bug it finds is fixed in the same pull.