Commit 7a8f64da authored by Oleksiy Mishchenko's avatar Oleksiy Mishchenko
Browse files

Pass request headers in to RAPI handlers.

Reviewed-by: iustinp
parent 86d9d3bb
......@@ -50,7 +50,7 @@ class RemoteApiHttpServer(http.HttpServer):
"""
(HandlerClass, items, args) = self._resmap.getController(req.request_path)
handler = HandlerClass(items, args, req.request_post_data)
handler = HandlerClass(items, args, req)
method = req.request_method.upper()
try:
......
......@@ -126,7 +126,7 @@ class R_Generic(object):
"""Generic class for resources.
"""
def __init__(self, items, queryargs, post_data):
def __init__(self, items, queryargs, req):
"""Generic resource constructor.
Args:
......@@ -136,7 +136,7 @@ class R_Generic(object):
"""
self.items = items
self.queryargs = queryargs
self.post_data = post_data
self.req = req
self.sn = None
def getSerialNumber(self):
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment