mirror of
https://github.com/ansible/awx.git
synced 2026-01-11 10:00:01 -03:30
fix a 500 error for Activity Stream job records w/ a missing JT
This commit is contained in:
parent
d0d08c2395
commit
c25dbb534f
@ -4687,10 +4687,10 @@ class ActivityStreamSerializer(BaseSerializer):
|
||||
if fk not in summary_keys:
|
||||
return
|
||||
related_obj = getattr(obj, summary_keys[fk], None)
|
||||
summary_fields[get_type_for_model(related_obj)] = []
|
||||
item = {}
|
||||
fields = SUMMARIZABLE_FK_FIELDS[summary_keys[fk]]
|
||||
if related_obj is not None:
|
||||
summary_fields[get_type_for_model(related_obj)] = []
|
||||
for field in fields:
|
||||
fval = getattr(related_obj, field, None)
|
||||
if fval is not None:
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user