Skip to content

Commit

Permalink
Django 4.0 - method request.is_ajax has been removed
Browse files Browse the repository at this point in the history
  • Loading branch information
agusmakmun authored Apr 26, 2024
1 parent 72fe936 commit 16664c4
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion tellme/views.py
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ def get_notification_function(path=None):


def post_feedback(request):
if request.method == 'POST' and request.is_ajax():
if request.method == 'POST' and request.headers.get('x-requested-with') == 'XMLHttpRequest':

# Copy Post data names into names used into the model in order to automatically create the model/form
# from the request dicts
Expand Down

0 comments on commit 16664c4

Please sign in to comment.