Permalink
Browse files

Merge pull request #56 from Gerrrr/master

Session endpoint cookie issue solved
  • Loading branch information...
2 parents 586c44e + fc8636b commit d734eecd483efa7de8cb02d04995504ef6e9f574 @mrjoes committed Sep 14, 2012
Showing with 3 additions and 7 deletions.
  1. +3 −7 tornadio2/session.py
View
@@ -100,7 +100,7 @@ def __init__(self, conn, server, request, expiry=None):
self.conn = conn(self)
# Call on_open.
- info = ConnectionInfo(request.remote_ip,
+ self.info = ConnectionInfo(request.remote_ip,
request.arguments,
request.cookies)
@@ -115,7 +115,7 @@ def __init__(self, conn, server, request, expiry=None):
# Endpoints
self.endpoints = dict()
- result = self.conn.on_open(info)
+ result = self.conn.on_open(self.info)
if result is not None and not result:
raise HTTPError(401)
@@ -302,11 +302,7 @@ def connect_endpoint(self, url):
self.send_message(proto.connect(endpoint))
- args = urlparse.parse_qs(urldata.query)
-
- info = ConnectionInfo(self.remote_ip, args, dict())
-
- if conn.on_open(info) == False:
+ if conn.on_open(self.info) == False:
self.disconnect_endpoint(endpoint)
def disconnect_endpoint(self, endpoint):

0 comments on commit d734eec

Please sign in to comment.