diff options
| author | Michael Merickel <michael@merickel.org> | 2016-03-14 23:25:10 -0500 |
|---|---|---|
| committer | Michael Merickel <michael@merickel.org> | 2016-03-14 23:26:41 -0500 |
| commit | a0945399b24fb38607107a55b12b7997723de2a0 (patch) | |
| tree | 5f3a329c4aa0f212a23b4b2d245cecc3b132fa0c /docs/narr/hooks.rst | |
| parent | 64bf7eec9b868fbc113341c7f5675c063aea002b (diff) | |
| download | pyramid-a0945399b24fb38607107a55b12b7997723de2a0.tar.gz pyramid-a0945399b24fb38607107a55b12b7997723de2a0.tar.bz2 pyramid-a0945399b24fb38607107a55b12b7997723de2a0.zip | |
do not guess at the name of the view deriver without further discussion
Diffstat (limited to 'docs/narr/hooks.rst')
| -rw-r--r-- | docs/narr/hooks.rst | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/docs/narr/hooks.rst b/docs/narr/hooks.rst index 3f66f4988..e3843cfbd 100644 --- a/docs/narr/hooks.rst +++ b/docs/narr/hooks.rst @@ -1631,7 +1631,7 @@ is a callable that can provide timing information for the view pipeline: response.headers['X-View-Performance'] = '%.3f' % (end - start,) return wrapper_view - config.add_view_deriver(timing_view) + config.add_view_deriver(timing_view, 'timing view') View derivers are unique in that they have access to most of the options passed to :meth:`pyramid.config.Configurator.add_view` in order to decide what @@ -1656,7 +1656,7 @@ token unless ``disable_csrf=True`` is passed to the view: require_csrf_view.options = ('disable_csrf',) - config.add_view_deriver(require_csrf_view) + config.add_view_deriver(require_csrf_view, 'require_csrf_view') def myview(request): return 'protected' |
