Skip to content

Commit

Permalink
make sure at least 1 other contact is created
Browse files Browse the repository at this point in the history
  • Loading branch information
rachidatecs committed Sep 27, 2024
1 parent 56c53f6 commit 7e0a915
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/registrar/fixtures/fixtures_requests.py
Original file line number Diff line number Diff line change
Expand Up @@ -244,7 +244,7 @@ def _set_many_to_many_relations(cls, request: DomainRequest, request_dict: dict)
request.other_contacts.add(Contact.objects.get_or_create(**contact)[0])
elif not request.other_contacts.exists():
other_contacts = [
Contact.objects.create(**cls.fake_contact()) for _ in range(random.randint(0, 3)) # nosec
Contact.objects.create(**cls.fake_contact()) for _ in range(random.randint(1, 3)) # nosec
]
request.other_contacts.add(*other_contacts)

Expand Down

0 comments on commit 7e0a915

Please sign in to comment.