From 69483e022ac3ddd02f086a264c3eb5e3345ccc0c Mon Sep 17 00:00:00 2001 From: Tim Graham Date: Mon, 6 Jul 2015 09:17:28 -0400 Subject: [PATCH] Removed some u string prefixes in code comments. --- django/template/base.py | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/django/template/base.py b/django/template/base.py index 43df12b6dd..71a97fda80 100644 --- a/django/template/base.py +++ b/django/template/base.py @@ -35,7 +35,7 @@ will be raised if the template doesn't have proper syntax. Sample code: >>> from django import template ->>> s = u'{% if test %}

{{ varvalue }}

{% endif %}' +>>> s = '{% if test %}

{{ varvalue }}

{% endif %}' >>> t = template.Template(s) (t is now a compiled template, and its render() method can be called multiple @@ -43,10 +43,10 @@ times with multiple contexts) >>> c = template.Context({'test':True, 'varvalue': 'Hello'}) >>> t.render(c) -u'

Hello

' +'

Hello

' >>> c = template.Context({'test':False, 'varvalue': 'Hello'}) >>> t.render(c) -u'' +'' """ from __future__ import unicode_literals @@ -756,15 +756,15 @@ class Variable(object): be a hard-coded string (if it begins and ends with single or double quote marks):: - >>> c = {'article': {'section':u'News'}} + >>> c = {'article': {'section':'News'}} >>> Variable('article.section').resolve(c) - u'News' + 'News' >>> Variable('article').resolve(c) - {'section': u'News'} + {'section': 'News'} >>> class AClass: pass >>> c = AClass() >>> c.article = AClass() - >>> c.article.section = u'News' + >>> c.article.section = 'News' (The example assumes VARIABLE_ATTRIBUTE_SEPARATOR is '.') """