diff --git a/Lagrange.OneBot/Core/Message/Entity/ReplySegment.cs b/Lagrange.OneBot/Core/Message/Entity/ReplySegment.cs index aba4edd28..c12496bc7 100644 --- a/Lagrange.OneBot/Core/Message/Entity/ReplySegment.cs +++ b/Lagrange.OneBot/Core/Message/Entity/ReplySegment.cs @@ -25,7 +25,7 @@ public override void Build(MessageBuilder builder, SegmentBase segment) { if (segment is ReplySegment reply && Database is not null) { - reply.TargetChain ??= (MessageChain)Database.GetCollection().FindOne(x => x.MessageHash == uint.Parse(reply.MessageId)); + reply.TargetChain ??= (MessageChain)Database.GetCollection().FindOne(x => x.MessageHash == (uint)int.Parse(reply.MessageId)); builder.Forward(reply.TargetChain); } } @@ -47,7 +47,7 @@ public override SegmentBase FromEntity(MessageChain chain, IMessageEntity entity return new ReplySegment { - MessageId = target.MessageHash.ToString() + MessageId = ((int)target.MessageHash).ToString() }; } } \ No newline at end of file