def _on_cancel(self, method_frame):
        """When the broker cancels a consumer, delete it from our internal
        dictionary.

        :param pika.frame.Method method_frame: The method frame received

        """
        if self._cancelled in method_frame.method.consumer_tag:
            # User-initiated cancel is waiting for Cancel-ok
            return

        self._cleanup_consumer_ref(method_frame.method.consumer_tag)
dataset/ETHPy150Open pika/pika/pika/channel.py/Channel._on_cancel/swapped operands of `in`