Document why we wrap it in the view, not the context

parent 015c00ab
......@@ -41,6 +41,8 @@ class Z2ProviderExpression(StringExpr):
if provider is None:
raise cp_interfaces.ContentProviderLookupError(name)
# A content provider's context (__parent__) is the view, not
# the context object.
if getattr(provider, '__of__', None) is not None:
provider = provider.__of__(view)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment