remove TODO from admin.py

This commit is contained in:
graham-dds 2019-10-28 14:01:54 -04:00
parent eb22d5ec1e
commit 5526356938

View File

@ -185,14 +185,13 @@ def remove_member(portfolio_id, portfolio_role_id):
raise UnauthorizedError(
g.current_user, "you can't delete the portfolios PPoC from the portfolio"
)
if (
portfolio_role.latest_invitation
and portfolio_role.status == PortfolioRoleStatus.PENDING
):
PortfolioInvitations.revoke(portfolio_role.latest_invitation.token)
else:
# TODO: should this cascade and disable any application and environment
# roles they might have?
PortfolioRoles.disable(portfolio_role=portfolio_role)
flash("portfolio_member_removed", member_name=portfolio_role.full_name)