Skip to content
Myr

Make before_first_request a decorator

Before adoption: this commit came in with the history the project adopted, so no landing records it.

authored by Armin Ronacher · committed by Armin Ronacher · parent ae45aed · Browse files · 2 files+2 added−0 removed
This commit

State

Before adoption: this commit came in with the history the project adopted, so no landing records it.

Diff stats

2 files+2 added−0 removed

  • other:+2 added−0 removed

2 files+2 added−0 removed

modified:flask/app.py+1 added
1203 unmodified lines
12041205 .. versionadded:: 0.81206 """1207 self.before_first_request_funcs.append(f)1208 return f12091210 @setupmethod1211 def after_request(self, f):1212 """Register a function to be run after each request. Your function
630 unmodified lines
modified:CHANGES+1 added
14 unmodified lines
15- Fixed an issue causing exceptions raised before entering a request or app16 context to be passed to teardown handlers.17- Fixed an issue with query parameters getting removed from requests in18 the test client when absolute URLs were requested.19- Made `@before_first_request` into a decorator as intended.2021Version 0.10.122--------------23
457 unmodified lines