def slaveof(self, host, port=None):
        """Make the server a slave of another instance,
        or promote it as master.

        Calling ``slaveof(None)`` will send ``SLAVEOF NO ONE``.

        .. versionchanged:: v0.2.6
           ``slaveof()`` form deprecated
           in favour of explicit ``slaveof(None)``.
        """
        if host is None and port is None:
            return self.execute(b'SLAVEOF', b'NO', b'ONE')
        return self.execute(b'SLAVEOF', host, port)
def slaveof ( self , host , port = None ) : if host is None and port is None : return self . execute ( b'SLAVEOF' , b'NO' , b'ONE' ) return self . execute ( b'SLAVEOF' , host , port )
Make the server a slave of another instance,
        or promote it as master.

        Calling ``slaveof(None)`` will send ``SLAVEOF NO ONE``.

        .. versionchanged:: v0.2.6
           ``slaveof()`` form deprecated
           in favour of explicit ``slaveof(None)``.