diff --git a/app/routers/api_crud.py b/app/routers/api_crud.py index a62012c..111289f 100644 --- a/app/routers/api_crud.py +++ b/app/routers/api_crud.py @@ -419,8 +419,8 @@ async def patch_obj( log.warning('We should not be here') return mk_resp(data=False, status_code=400, response=commons.response) - table_name = obj_type_li[obj_name]['tbl_name_update'] - exclude = obj_type_li[obj_name]['exclude_for_db'] + table_name = obj_type_li[obj_name].get('tbl_name_update') + exclude = obj_type_li[obj_name].get('exclude_for_db') # ### SECTION ### Secondary data validation # obj_id_random = obj_id # This might need to be used later for the response data