Skip to content

Commit

Permalink
OpenConceptLab/ocl_issues#1945 | deleting search_meta from CSV response
Browse files Browse the repository at this point in the history
  • Loading branch information
snyaggarwal committed Oct 17, 2024
1 parent b8649b3 commit a248ab5
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions core/common/serializers.py
Original file line number Diff line number Diff line change
Expand Up @@ -199,8 +199,10 @@ def __init__(self, *args, **kwargs): # pylint: disable=too-many-branches
request = get(kwargs, 'context.request')
params = get(request, 'query_params')
self.query_params = (params or {}) if isinstance(params, dict) else (params.dict() if params else {})
self.include_search_meta = self.query_params.get(
INCLUDE_SEARCH_META_PARAM) in TRUTHY and self.query_params.get('q')
self.include_search_meta = (
self.query_params.get(
INCLUDE_SEARCH_META_PARAM) in TRUTHY and self.query_params.get('q')
) or self.query_params.get('csv', False)

try:
if not self.include_search_meta:
Expand Down

0 comments on commit a248ab5

Please sign in to comment.