[ADD] status_code to LazyResponse constructor
bzr revid: fme@openerp.com-20131204145613-721x3ij2ylpykzgw
This commit is contained in:
+3
-1
@@ -798,8 +798,10 @@ class LazyResponse(werkzeug.wrappers.Response):
|
||||
""" Lazy werkzeug response.
|
||||
API not yet frozen"""
|
||||
|
||||
def __init__(self, callback, **kwargs):
|
||||
def __init__(self, callback, status_code=None, **kwargs):
|
||||
super(LazyResponse, self).__init__(mimetype='text/html')
|
||||
if status_code:
|
||||
self.status_code = status_code
|
||||
self.callback = callback
|
||||
self.params = kwargs
|
||||
def process(self):
|
||||
|
||||
Reference in New Issue
Block a user