Skip to content

Commit 975966f

Browse files
authored
Don't remove users from contracts for now (#3033)
1 parent f45653f commit 975966f

File tree

1 file changed

+2
-5
lines changed

1 file changed

+2
-5
lines changed

b2b/models.py

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -152,7 +152,7 @@ def add_user_contracts(self, user):
152152

153153
return contracts_qs.count()
154154

155-
def remove_user_contracts(self, user):
155+
def remove_user_contracts(self, user): # noqa: ARG002
156156
"""
157157
Remove managed contracts from the given user.
158158
@@ -161,10 +161,7 @@ def remove_user_contracts(self, user):
161161
Returns:
162162
- int: number of contracts removed
163163
"""
164-
165-
return user.b2b_contracts.through.objects.filter(
166-
contractpage_id__in=self.contracts.all().values_list("id", flat=True)
167-
).delete()
164+
return 0
168165

169166
def __str__(self):
170167
"""Return a reasonable representation of the org as a string."""

0 commit comments

Comments
 (0)