django icon indicating copy to clipboard operation
django copied to clipboard

Updated docs example to use cookie-based storage for timezone handling

Open rob101 opened this issue 7 months ago • 0 comments

The current example for TimezoneMiddleware in the Django documentation uses sessions to store the user's time zone. With Django 4.0, the framework has deprecated the use of sessions for storing the user's language preference, opting for cookies instead. It seems logical to align the handling of time zones with this change for consistency and the advantages it offers.

See https://docs.djangoproject.com/en/dev/internals/deprecation/#deprecation-removed-in-4-0 and https://docs.djangoproject.com/en/dev/releases/3.0/#id3

rob101 avatar Sep 24 '23 14:09 rob101