summaryrefslogtreecommitdiff
path: root/docs
diff options
context:
space:
mode:
authorcewing <cris@crisewing.com>2017-06-03 16:06:38 -0700
committercewing <cris@crisewing.com>2017-06-03 16:07:03 -0700
commitf42ab136cd5d2c98c34b101d458750f638380d08 (patch)
tree34be1b0d57041d3f1600cd97f36562b9b728ad22 /docs
parent981a9df80716ca622324d653117b9c7c3ada70c2 (diff)
downloadpyramid-f42ab136cd5d2c98c34b101d458750f638380d08.tar.gz
pyramid-f42ab136cd5d2c98c34b101d458750f638380d08.tar.bz2
pyramid-f42ab136cd5d2c98c34b101d458750f638380d08.zip
use str in deference to Py3 style over Py2
Diffstat (limited to 'docs')
-rw-r--r--docs/narr/advanced-features.rst4
1 files changed, 2 insertions, 2 deletions
diff --git a/docs/narr/advanced-features.rst b/docs/narr/advanced-features.rst
index ae28ba41b..9ed0cc712 100644
--- a/docs/narr/advanced-features.rst
+++ b/docs/narr/advanced-features.rst
@@ -252,7 +252,7 @@ A new response adapter is registered in configuration:
if __name__ == '__main__':
config = Configurator()
- config.add_response_adapter(string_response_adapter, basestring)
+ config.add_response_adapter(string_response_adapter, str)
With that, you may return strings from any of your view callables, e.g.:
@@ -288,7 +288,7 @@ and return codes:
if __name__ == '__main__':
config = Configurator()
- config.add_response_adapter(string_response_adapter, basestring)
+ config.add_response_adapter(string_response_adapter, str)
config.add_response_adapter(tuple_response_adapter, tuple)
With this, both of these views will work as expected: