Skip to content

Commit

Permalink
Merge branch '3175-courthouses' of https://github.com/freelawproject/…
Browse files Browse the repository at this point in the history
…courtlistener into 3175-courthouses
  • Loading branch information
flooie committed Sep 26, 2023
2 parents 31369f9 + 9ee5f7a commit 8b3add8
Showing 1 changed file with 8 additions and 3 deletions.
11 changes: 8 additions & 3 deletions cl/recap/mergers.py
Original file line number Diff line number Diff line change
Expand Up @@ -369,10 +369,15 @@ async def update_docket_appellate_metadata(d, docket_data):
# our whole save of the docket fails.
d.appeal_from_id = cl_id

try:
d_og_info = await OriginatingCourtInformation.objects.aget(docket=d)
except OriginatingCourtInformation.DoesNotExist:
if d.pk is None:
d_og_info = OriginatingCourtInformation()
else:
try:
d_og_info = await OriginatingCourtInformation.objects.aget(
docket=d
)
except OriginatingCourtInformation.DoesNotExist:
d_og_info = OriginatingCourtInformation()

# Ensure we don't share A-Numbers, which can sometimes be in the docket
# number field.
Expand Down

0 comments on commit 8b3add8

Please sign in to comment.