summaryrefslogtreecommitdiff
path: root/docs
diff options
context:
space:
mode:
authorChris McDonough <chrism@agendaless.com>2010-09-05 15:48:05 +0000
committerChris McDonough <chrism@agendaless.com>2010-09-05 15:48:05 +0000
commit97fbf9972745e6bd59a284b94d2e5457fc4ff6d8 (patch)
treeeaba5bc80a3f9ccb16da1681b04773bc1a0bb1c4 /docs
parentc87fa63f2881702a3452a04fb555b4eeebf79342 (diff)
downloadpyramid-97fbf9972745e6bd59a284b94d2e5457fc4ff6d8.tar.gz
pyramid-97fbf9972745e6bd59a284b94d2e5457fc4ff6d8.tar.bz2
pyramid-97fbf9972745e6bd59a284b94d2e5457fc4ff6d8.zip
fix
Diffstat (limited to 'docs')
-rw-r--r--docs/narr/hooks.rst13
1 files changed, 7 insertions, 6 deletions
diff --git a/docs/narr/hooks.rst b/docs/narr/hooks.rst
index 9da459641..70e3f3759 100644
--- a/docs/narr/hooks.rst
+++ b/docs/narr/hooks.rst
@@ -416,10 +416,11 @@ argument to the constructor of the :term:`configurator`.
.. code-block:: python
:linenos:
- def globals_factory(system):
+ def renderer_globals_factory(system):
return {'a':1}
- config = Configurator(renderer_globals_factory=globals_factory)
+ config = Configurator(
+ renderer_globals_factory=renderer_globals_factory)
Such a callback must accept a single positional argument (notionally
named ``system``) which will contain the original system values. It
@@ -429,8 +430,8 @@ values present in the system dictionary.
A renderer globals factory can alternately be registered via ZCML as a
through the use of the ZCML ``utility`` directive. In the below, we
-assume a ``globals_factory`` function lives in a package named
-``mypackage.mymodule``.
+assume a ``renderers_globals_factory`` function lives in a package
+named ``mypackage.mymodule``.
.. code-block:: xml
:linenos:
@@ -451,11 +452,11 @@ method:
from repoze.bfg.configuration import Configurator
- def globals_factory(system):
+ def renderer_globals_factory(system):
return {'a':1}
config = Configurator()
- config.set_renderer_globals_factory(globals_factory)
+ config.set_renderer_globals_factory(renderer_globals_factory)
.. _registering_configuration_decorators: