Skip to content

Commit

Permalink
get_response must be executable
Browse files Browse the repository at this point in the history
  • Loading branch information
patroqueeet committed Feb 1, 2023
1 parent 133e4fa commit 6df92fc
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion django_walletpass/classviews.py
Original file line number Diff line number Diff line change
Expand Up @@ -113,7 +113,11 @@ def retrieve(self, request, pass_type_id, serial_number):
response['Content-Disposition'] = 'attachment; filename=pass.pkpass'

response['Last-Modified'] = http_date(timegm(pass_.updated_at.utctimetuple()))
return ConditionalGetMiddleware(get_response=response)(request)

def _get_response(request):
return response

return ConditionalGetMiddleware(get_response=_get_response)(request)


# TODO: use ModelViewSet
Expand Down

0 comments on commit 6df92fc

Please sign in to comment.