Skip to content

Commit

Permalink
attempt at Django 5 support
Browse files Browse the repository at this point in the history
  • Loading branch information
nickmccullum authored and jheld committed Mar 19, 2024
1 parent 060af82 commit 1c8f8c1
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion django_twilio/admin.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,12 +10,12 @@
from .models import Caller, Credential


@admin.register(Caller)
class CallerAdmin(admin.ModelAdmin):
"""This class provides admin panel integration for our
:class:`django_twilio.models.Caller` model.
"""
list_display = ('__str__', 'blacklisted')


admin.site.register(Caller, CallerAdmin)
admin.site.register(Credential)
2 changes: 1 addition & 1 deletion django_twilio/decorators.py
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,7 @@ def decorator(request_or_self, *args, **kwargs):
try:
validator = RequestValidator(TWILIO_AUTH_TOKEN)
url = request.build_absolute_uri()
signature = request.META['HTTP_X_TWILIO_SIGNATURE']
signature = request.headers['x-twilio-signature']
except (AttributeError, KeyError):
return HttpResponseForbidden()

Expand Down
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
# For the official support, please visit:
# https://docs.djangoproject.com/en/4.0/faq/install/#what-python-version-can-i-use-with-django
if sys.version_info[1] in [8, 9, 10, 11]:
django_python_version_install = "Django>=4.0,<4.3"
django_python_version_install = "Django>=4.0,<=5.0"
INSTALL_PYTHON_REQUIRES.append(django_python_version_install)

setup(
Expand Down

0 comments on commit 1c8f8c1

Please sign in to comment.