mirror of
https://github.com/appwrite/appwrite.git
synced 2026-05-26 13:51:13 +00:00
fix linter
This commit is contained in:
@@ -3040,13 +3040,13 @@ App::delete('/v1/account')
|
||||
if ($user->isEmpty()) {
|
||||
throw new Exception(Exception::USER_NOT_FOUND);
|
||||
}
|
||||
|
||||
|
||||
if ($project->getId() === 'console') {
|
||||
// get all memberships
|
||||
$memberships = $user->getAttribute('memberships', []);
|
||||
foreach ($memberships as $membership) {
|
||||
// prevent deletion if at lease one active membership
|
||||
if($membership->getAttribute('confirm', false)) {
|
||||
if ($membership->getAttribute('confirm', false)) {
|
||||
throw new Exception(Exception::USER_DELETION_WITH_ACTIVE_TEAMS);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user