Browse Source

Document that the return values of teardown functions are ignored

pull/1338/head
Chris Rebert 10 years ago
parent
commit
6a2524634d
  1. 4
      flask/app.py

4
flask/app.py

@ -1304,6 +1304,8 @@ class Flask(_PackageBoundObject):
When a teardown function was called because of a exception it will
be passed an error object.
The return values of teardown functions are ignored.
.. admonition:: Debug Note
In debug mode Flask will not tear down a request on an exception
@ -1338,6 +1340,8 @@ class Flask(_PackageBoundObject):
When a teardown function was called because of an exception it will
be passed an error object.
The return values of teardown functions are ignored.
.. versionadded:: 0.9
"""
self.teardown_appcontext_funcs.append(f)

Loading…
Cancel
Save