mirror of
https://github.com/cisagov/manage.get.gov.git
synced 2025-07-28 05:26:28 +02:00
lint
This commit is contained in:
parent
c2a07a8983
commit
641692d963
1 changed files with 2 additions and 2 deletions
|
@ -3241,7 +3241,7 @@ class PortfolioAdmin(ListHeaderAdmin):
|
|||
if hasattr(obj, "creator") is False:
|
||||
# ---- update creator ----
|
||||
# Set the creator field to the current admin user
|
||||
obj.creator = request.user if request.user.is_authenticated else None
|
||||
obj.creator = request.user if request.user.is_authenticated else None # type: ignore
|
||||
# ---- update organization name ----
|
||||
# org name will be the same as federal agency, if it is federal,
|
||||
# otherwise it will be the actual org name. If nothing is entered for
|
||||
|
@ -3263,7 +3263,7 @@ class PortfolioAdmin(ListHeaderAdmin):
|
|||
if obj.federal_agency and obj.federal_agency.agency != "Non-Federal Agency":
|
||||
if obj.federal_agency.so_federal_agency.first() == obj.senior_official:
|
||||
obj.senior_official = None
|
||||
obj.federal_agency = FederalAgency.objects.filter(agency="Non-Federal Agency").first()
|
||||
obj.federal_agency = FederalAgency.objects.filter(agency="Non-Federal Agency").first() # type: ignore
|
||||
|
||||
super().save_model(request, obj, form, change)
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue