From 46a90749f839c3d64aa05458cef825f56e9c702d Mon Sep 17 00:00:00 2001 From: mathieui Date: Fri, 30 Sep 2016 21:25:36 +0200 Subject: Fix uses of super() in the codebase MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Fix #3165, we don’t need to use the long form to get the superobject in our supported python versions. --- docs/getting_started/echobot.rst | 6 +++--- docs/getting_started/sendlogout.rst | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) (limited to 'docs/getting_started') diff --git a/docs/getting_started/echobot.rst b/docs/getting_started/echobot.rst index 0137985c..63915ca4 100644 --- a/docs/getting_started/echobot.rst +++ b/docs/getting_started/echobot.rst @@ -70,7 +70,7 @@ as well. class EchoBot(slixmpp.ClientXMPP): def __init__(self, jid, password): - super(EchoBot, self).__init__(jid, password) + super().__init__(jid, password) Handling Session Start ~~~~~~~~~~~~~~~~~~~~~~ @@ -83,7 +83,7 @@ started. To do that, we will register an event handler for the :term:`session_st .. code-block:: python def __init__(self, jid, password): - super(EchoBot, self).__init__(jid, password) + super().__init__(jid, password) self.add_event_handler('session_start', self.start) @@ -153,7 +153,7 @@ whenever a messsage is received. .. code-block:: python def __init__(self, jid, password): - super(EchoBot, self).__init__(jid, password) + super().__init__(jid, password) self.add_event_handler('session_start', self.start) self.add_event_handler('message', self.message) diff --git a/docs/getting_started/sendlogout.rst b/docs/getting_started/sendlogout.rst index d5882c42..a27976c5 100644 --- a/docs/getting_started/sendlogout.rst +++ b/docs/getting_started/sendlogout.rst @@ -24,7 +24,7 @@ for the JID that will receive our message, and the string content of the message class SendMsgBot(slixmpp.ClientXMPP): def __init__(self, jid, password, recipient, msg): - super(SendMsgBot, self).__init__(jid, password) + super().__init__(jid, password) self.recipient = recipient self.msg = msg -- cgit v1.2.3