From 6a28ccbf64f1f56382209ddfb84bf41ed8e49b52 Mon Sep 17 00:00:00 2001 From: guozhigq Date: Fri, 28 Jun 2024 23:44:48 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20=E8=AF=84=E8=AE=BA=E5=86=85=E5=AE=B9?= =?UTF-8?q?=E8=A7=A3=E6=9E=90?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- lib/pages/video/detail/reply/widgets/reply_item.dart | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/lib/pages/video/detail/reply/widgets/reply_item.dart b/lib/pages/video/detail/reply/widgets/reply_item.dart index 02d004e8..ebb266cd 100644 --- a/lib/pages/video/detail/reply/widgets/reply_item.dart +++ b/lib/pages/video/detail/reply/widgets/reply_item.dart @@ -700,9 +700,10 @@ InlineSpan buildContent( ); // 只显示一次 matchedStrs.add(matchStr); - } else if (content - .topicsMeta[matchStr.substring(1, matchStr.length - 1)] != - null) { + } else if (content.topicsMeta.keys.isNotEmpty && + matchStr.length > 1 && + content.topicsMeta[matchStr.substring(1, matchStr.length - 1)] != + null) { spanChilds.add( TextSpan( text: matchStr,