Repository: Rapptz/discord.py
File: discord/message.py (Python)

Code before:
    Attributes
    -----------
    id: :class:`int`
        The interaction ID.
    type: :class:`InteractionType`
        The interaction type.
    user: :class:`User`
        The user that invoked the interaction.
    original_response_message_id: Optional[:class:`int`]
        The ID of the original response message if the message is a follow-up.
    interacted_message_id: Optional[:class:`int`]
        The ID of the message that containes the interactive components, if applicable.
    modal_interaction: Optional[:class:`.MessageInteractionMetadata`]
        The metadata of the modal submit interaction that triggered this interaction, if applicable.
    """

    __slots__: Tuple[str, ...] = (
        'id',
        'type',
        'user',
        'original_response_message_id',
        'interacted_message_id',
        'modal_interaction',
        '_integration_owners',
        '__state',
        '__guild',
    )

    def __init__(self, *, state: ConnectionState, guild: Optional[Guild], data: MessageInteractionMetadataPayload) -> None:
        self.__guild: Optional[Guild] = guild
        self.__state: ConnectionState = state

        self.id: int = int(data['id'])
        self.type: InteractionType = try_enum(InteractionType, data['type'])
        self.user = state.create_user(data['user'])
        self._integration_owners: Dict[int, int] = {
            int(key): int(value) for key, value in data.get("authorizing_integration_owners", {}).items()
        }

        self.original_response_message_id: Optional[int] = None
        try:
            self.original_response_message_id = int(data['original_response_message_id'])
        except KeyError:
            pass

        self.interacted_message_id: Optional[int] = None
        try:
            self.interacted_message_id = int(data['interacted_message_id'])
        except KeyError:
            pass


Review comment (suggestion):
```suggestion
        '_state',
        '_guild',
```

Please rename these.

Code after:
    Attributes
    -----------
    id: :class:`int`
        The interaction ID.
    type: :class:`InteractionType`
        The interaction type.
    user: :class:`User`
        The user that invoked the interaction.
    original_response_message_id: Optional[:class:`int`]
        The ID of the original response message if the message is a follow-up.
    interacted_message_id: Optional[:class:`int`]
        The ID of the message that containes the interactive components, if applicable.
    modal_interaction: Optional[:class:`.MessageInteractionMetadata`]
        The metadata of the modal submit interaction that triggered this interaction, if applicable.
    """

    __slots__: Tuple[str, ...] = (
        'id',
        'type',
        'user',
        'original_response_message_id',
        'interacted_message_id',
        'modal_interaction',
        '_integration_owners',
        '_state',
        '_guild',
    )

    def __init__(self, *, state: ConnectionState, guild: Optional[Guild], data: MessageInteractionMetadataPayload) -> None:
        self._guild: Optional[Guild] = guild
        self._state: ConnectionState = state

        self.id: int = int(data['id'])
        self.type: InteractionType = try_enum(InteractionType, data['type'])
        self.user = state.create_user(data['user'])
        self._integration_owners: Dict[int, int] = {
            int(key): int(value) for key, value in data.get('authorizing_integration_owners', {}).items()
        }

        self.original_response_message_id: Optional[int] = None
        try:
            self.original_response_message_id = int(data['original_response_message_id'])
        except KeyError:
            pass

        self.interacted_message_id: Optional[int] = None
        try:
            self.interacted_message_id = int(data['interacted_message_id'])
        except KeyError:
            pass