From 3a221ce1cc4aba42d2de9369e4ccce3e1002bbad Mon Sep 17 00:00:00 2001 From: David Kennedy Date: Wed, 10 Jan 2024 14:35:52 -0500 Subject: [PATCH] update for code clarity --- src/registrar/forms/application_wizard.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/registrar/forms/application_wizard.py b/src/registrar/forms/application_wizard.py index 64fbdcdd6..82821f8d9 100644 --- a/src/registrar/forms/application_wizard.py +++ b/src/registrar/forms/application_wizard.py @@ -96,7 +96,7 @@ class RegistrarFormSet(forms.BaseFormSet): """ raise NotImplementedError - def test_if_more_than_one_join(self, db_obj, rel, related_name): + def has_more_than_one_join(self, db_obj, rel, related_name): """Helper for finding whether an object is joined more than once.""" # threshold is the number of related objects that are acceptable # when determining if related objects exist. threshold is 0 for most @@ -165,7 +165,7 @@ class RegistrarFormSet(forms.BaseFormSet): # matching database object exists, update it if db_obj is not None and cleaned: if should_delete(cleaned): - if any(self.test_if_more_than_one_join(db_obj, rel, related_name) for rel in reverse_joins): + if any(self.has_more_than_one_join(db_obj, rel, related_name) for rel in reverse_joins): # Remove the specific relationship without deleting the object getattr(db_obj, related_name).remove(self.application) else: