Edits for ForeignKey record 2 redundant changes in activity stream
Closed this issue · 0 comments
AlanCoding commented
Steps
animal = Animal.objects.create()
animal.owner = User.objects.first()
animal.save()
GET http://127.0.0.1:8000/api/v1/activitystream/?order_by=-created
Actual Results
{
"id": 14,
"url": "",
"related": {
"created_by": "/api/v1/users/1/"
},
"summary_fields": {
"created_by": {
"id": 1,
"username": "_system",
"first_name": "",
"last_name": ""
},
"content_object": {
"id": 1,
"name": ""
}
},
"created": "2024-04-08T15:02:28.469397Z",
"created_by": 1,
"operation": "update",
"changes": {
"added_fields": {},
"changed_fields": {
"owner": [
null,
"_system"
],
"owner_id": [
null,
1
]
},
"removed_fields": {}
},
"content_type": 49,
"object_id": "1",
"related_content_type": null,
"related_object_id": null,
"content_type_model": "animal",
"related_content_type_model": null
}
Expected Results
I thought that only "owner" or "owner_id" would be in changes? Maybe I need clarification.