From: GunWoo Choi Date: Tue, 24 Nov 2015 05:12:07 +0000 (+0900) Subject: Use super() to call super "__init__()" X-Git-Tag: v4.4.0b1~64^2 X-Git-Url: http://git.ipfire.org/gitweb/gitweb.cgi?a=commitdiff_plain;h=refs%2Fpull%2F1593%2Fhead;p=thirdparty%2Ftornado.git Use super() to call super "__init__()" Calling super method by Request.__init__(self) cannot handle MRO properly. --- diff --git a/tornado/websocket.py b/tornado/websocket.py index 11e526687..f5e3dbd7f 100644 --- a/tornado/websocket.py +++ b/tornado/websocket.py @@ -128,8 +128,7 @@ class WebSocketHandler(tornado.web.RequestHandler): to accept it before the websocket connection will succeed. """ def __init__(self, application, request, **kwargs): - tornado.web.RequestHandler.__init__(self, application, request, - **kwargs) + super(WebSocketHandler, self).__init__(application, request, **kwargs) self.ws_connection = None self.close_code = None self.close_reason = None