Skip to content
Snippets Groups Projects
Commit 6d85e757 authored by Rajmund Hruška's avatar Rajmund Hruška
Browse files

Fix: Remove unnecessary items from the response. (Redmine issue: #7578)

parent 10c798ed
No related branches found
No related tags found
No related merge requests found
...@@ -473,6 +473,16 @@ class APIDashboardView(AJAXMixin, AbstractDashboardView): # pylint: disable=loc ...@@ -473,6 +473,16 @@ class APIDashboardView(AJAXMixin, AbstractDashboardView): # pylint: disable=loc
def get_view_name(cls): def get_view_name(cls):
return 'apidashboard' return 'apidashboard'
def process_response_context(self):
super().process_response_context()
# Prevent certain response context keys to appear in final response.
for key in ('items', 'quicksearch_list'):
try:
del self.response_context[key]
except KeyError:
pass
return self.response_context
class DeleteView(HTMLMixin, SQLAlchemyMixin, ItemDeleteView): # pylint: disable=locally-disabled,too-many-ancestors class DeleteView(HTMLMixin, SQLAlchemyMixin, ItemDeleteView): # pylint: disable=locally-disabled,too-many-ancestors
""" """
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment