Greg Thompson commited on
Commit
26c091c
·
1 Parent(s): 27d20fd

Remove fields from request object

Browse files
Files changed (1) hide show
  1. mathtext_fastapi/nlu.py +7 -0
mathtext_fastapi/nlu.py CHANGED
@@ -64,6 +64,13 @@ def prepare_message_data_for_logging(message_data, nlu_response, request_object)
64
  }
65
  contact_data_log = get_or_create_supabase_entry('contact', contact_data)
66
 
 
 
 
 
 
 
 
67
  message_data = {
68
  'contact': contact_data_log.data[0]['id'], # FK
69
  'original_message_id': message_data['message']['id'],
 
64
  }
65
  contact_data_log = get_or_create_supabase_entry('contact', contact_data)
66
 
67
+
68
+ del request_object['message']['_vnd']['v1']['chat']['owner']
69
+ del request_object['message']['_vnd']['v1']['chat']['assigned_to']
70
+ del request_object['message']['_vnd']['v1']['author']['id']
71
+ del request_object['message']['_vnd']['v1']['author']['name']
72
+ del request_object['message']['from']
73
+
74
  message_data = {
75
  'contact': contact_data_log.data[0]['id'], # FK
76
  'original_message_id': message_data['message']['id'],