diff options
| author | Michael <michael-k@users.noreply.github.com> | 2017-09-04 18:40:56 +0000 |
|---|---|---|
| committer | Tim Graham <timograham@gmail.com> | 2017-09-04 14:41:26 -0400 |
| commit | db7dfbff53765bb42b51314b4d48d11e42a218db (patch) | |
| tree | 70bb017199e8487e1aee7f40d93f814d1a7381c0 | |
| parent | 2f3613aae6a133c6c043d34c7f429fb4b5b2efa3 (diff) | |
[1.10.x] Fixed #28568 -- Fixed typo in docs/ref/models/database-functions.txt.
And made an example use naming consistent with the rest of the doc.
Backport of 3f2b1d926bb3a72b4c3d2cd958455ebb9b4ca458 from master
| -rw-r--r-- | docs/ref/models/database-functions.txt | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/docs/ref/models/database-functions.txt b/docs/ref/models/database-functions.txt index 1bdfe42b6b..f257a22216 100644 --- a/docs/ref/models/database-functions.txt +++ b/docs/ref/models/database-functions.txt @@ -480,8 +480,8 @@ the Melbourne timezone (UTC +10:00), which changes the day, weekday, and hour values that are returned:: >>> import pytz - >>> tzinfo = pytz.timezone('Australia/Melbourne') # UTC+10:00 - >>> with timezone.override(tzinfo): + >>> melb = pytz.timezone('Australia/Melbourne') # UTC+10:00 + >>> with timezone.override(melb): ... Experiment.objects.annotate( ... day=ExtractDay('start_datetime'), ... weekday=ExtractWeekDay('start_datetime'), @@ -495,7 +495,7 @@ Explicitly passing the timezone to the ``Extract`` function behaves in the same way, and takes priority over an active timezone:: >>> import pytz - >>> tzinfo = pytz.timezone('Australia/Melbourne') + >>> melb = pytz.timezone('Australia/Melbourne') >>> Experiment.objects.annotate( ... day=ExtractDay('start_datetime', tzinfo=melb), ... weekday=ExtractWeekDay('start_datetime', tzinfo=melb), |
