Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Refs #1400 - Reverted r3269. Template variable evalution should follo…

…w Python norms.

git-svn-id: http://code.djangoproject.com/svn/django/trunk@3680 bcc190cf-cafb-0310-a4f2-bffc1f526a37
  • Loading branch information...
commit a619b2b8715f775f0090a3f47f0d327620b9ed65 1 parent ff4f249
Russell Keith-Magee freakboy3742 authored
Showing with 1 addition and 5 deletions.
  1. +1 −5 django/template/__init__.py
6 django/template/__init__.py
View
@@ -614,11 +614,7 @@ def resolve_variable(path, context):
(The example assumes VARIABLE_ATTRIBUTE_SEPARATOR is '.')
"""
- if path == 'False':
- current = False
- elif path == 'True':
- current = True
- elif path[0].isdigit():
+ if path[0].isdigit():
number_type = '.' in path and float or int
try:
current = number_type(path)
Please sign in to comment.
Something went wrong with that request. Please try again.