Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Z
Zope
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
Zope
Commits
1c40e012
Commit
1c40e012
authored
Jan 07, 2007
by
Andreas Jung
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
merge from HEAD
parent
8730ec04
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
10 additions
and
1 deletion
+10
-1
lib/python/Products/PageTemplates/Expressions.py
lib/python/Products/PageTemplates/Expressions.py
+10
-1
No files found.
lib/python/Products/PageTemplates/Expressions.py
View file @
1c40e012
...
@@ -21,6 +21,7 @@ $Id$
...
@@ -21,6 +21,7 @@ $Id$
import
logging
import
logging
from
zope.component
import
getUtility
from
zope.component
import
getUtility
from
zope.component.interfaces
import
ComponentLookupError
from
zope.interface
import
implements
from
zope.interface
import
implements
from
zope.tales.tales
import
Context
,
Iterator
from
zope.tales.tales
import
Context
,
Iterator
from
zope.tales.expressions
import
PathExpr
,
StringExpr
,
NotExpr
from
zope.tales.expressions
import
PathExpr
,
StringExpr
,
NotExpr
...
@@ -199,7 +200,15 @@ class ZopeContext(Context):
...
@@ -199,7 +200,15 @@ class ZopeContext(Context):
elif
isinstance
(
text
,
str
):
elif
isinstance
(
text
,
str
):
# bahh...non-unicode string..we need to convert it to unicode
# bahh...non-unicode string..we need to convert it to unicode
resolver
=
getUtility
(
IUnicodeEncodingConflictResolver
)
# catch ComponentLookupError in order to make tests shut-up.
# This should not be a problem since it won't change the old
# default behavior
try
:
resolver
=
getUtility
(
IUnicodeEncodingConflictResolver
)
except
ComponentLookupError
:
return
unicode
(
text
)
try
:
try
:
return
resolver
.
resolve
(
self
.
contexts
[
'context'
],
text
,
expr
)
return
resolver
.
resolve
(
self
.
contexts
[
'context'
],
text
,
expr
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment