diff --git a/packages/nonebot-adapter-mirai/nonebot/adapters/mirai/message.py b/packages/nonebot-adapter-mirai/nonebot/adapters/mirai/message.py index 34ea948f..14d6f9e8 100644 --- a/packages/nonebot-adapter-mirai/nonebot/adapters/mirai/message.py +++ b/packages/nonebot-adapter-mirai/nonebot/adapters/mirai/message.py @@ -274,22 +274,6 @@ class MessageChain(BaseMessage[MessageSegment]): def get_segment_class(cls) -> Type[MessageSegment]: return MessageSegment - @overrides(BaseMessage) - def __init__(self, message: Union[List[Dict[str, - Any]], Iterable[MessageSegment], - MessageSegment, str], **kwargs): - super().__init__(**kwargs) - if isinstance(message, MessageSegment): - self.append(message) - elif isinstance(message, str): - self.append(MessageSegment.plain(text=message)) - elif isinstance(message, Iterable): - self.extend(self._construct(message)) - else: - raise ValueError( - f'Type {type(message).__name__} is not supported in mirai adapter.' - ) - @overrides(BaseMessage) def _construct( self, message: Union[List[Dict[str, Any]], Iterable[MessageSegment]]