mirror of
https://github.com/cisagov/manage.get.gov.git
synced 2025-07-26 04:28:39 +02:00
cleaned up json endpoint with comment and formatting
This commit is contained in:
parent
1b89031a54
commit
3f399db985
1 changed files with 5 additions and 3 deletions
|
@ -31,9 +31,11 @@ def get_domains_json(request):
|
|||
if status_param:
|
||||
status_list = status_param.split(",")
|
||||
|
||||
# if unknown is in status_list, append 'dns needed'
|
||||
if 'unknown' in status_list:
|
||||
status_list.append('dns needed')
|
||||
# if unknown is in status_list, append 'dns needed' since both
|
||||
# unknown and dns needed display as DNS Needed, and both are
|
||||
# searchable via state parameter of 'unknown'
|
||||
if "unknown" in status_list:
|
||||
status_list.append("dns needed")
|
||||
|
||||
# Split the status list into normal states and custom states
|
||||
normal_states = [state for state in status_list if state in Domain.State.values]
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue