<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def get_subscribers(cls, active_only=True):
 """Returns a list of Recipient objects subscribed for this message type. :param bool active_only: Flag whether :return: """

        subscribers_raw = Subscription.get_for_message_cls(cls.alias)
        subscribers = []

        for subscriber in subscribers_raw:
            messenger_cls = subscriber.messenger_cls
            address = subscriber.address
            recipient = subscriber.recipient

            # Do not send messages to inactive users.
            if active_only and recipient:
                if not getattr(recipient, 'is_active', False):
                    continue

            if address is None:
                try:
                    address = get_registered_messenger_object(messenger_cls).get_address(recipient)
                except UnknownMessengerError:
                    pass

            if address and isinstance(address, string_types):
                subscribers.append(Recipient(messenger_cls, recipient, address))

        return subscribers