From 3da8a63df260adefdfacade28c96a0ce52be1dca Mon Sep 17 00:00:00 2001 From: jiahao <283739569@qq.com> Date: Thu, 26 Mar 2020 16:07:22 +0800 Subject: [PATCH] 1 --- lib/chat/ChatPage.dart | 2 +- lib/chat/group_chat_view.dart | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/chat/ChatPage.dart b/lib/chat/ChatPage.dart index 1a33fd9..0da9f09 100644 --- a/lib/chat/ChatPage.dart +++ b/lib/chat/ChatPage.dart @@ -216,7 +216,7 @@ class _ChatPageState extends State { MsgModel msg = MsgHandler.createSendMsg( ChatType.valueOf(originMsg.msgType), originMsg.msgContent); msg.extraInfo = originMsg.extraInfo; - if(originMsg.extraFile.contains('http')){ + if(originMsg.extraFile==null ||originMsg.extraFile.contains('http')){ msg.extraFile = originMsg.extraFile; }else{ msg.extraFile = UploadUtil().getFullUrl(originMsg.extraFile, originMsg.sessionId, originMsg.channelType); diff --git a/lib/chat/group_chat_view.dart b/lib/chat/group_chat_view.dart index 631d9c7..ef5d1cc 100644 --- a/lib/chat/group_chat_view.dart +++ b/lib/chat/group_chat_view.dart @@ -113,7 +113,7 @@ class _GroupChatPageState extends State { channelType: ChatChannelType.Group); msg.extraInfo = originMsg.extraInfo; // msg.extraFile = originMsg.extraFile; - if(originMsg.extraFile.contains('http')){ + if(originMsg.extraFile==null ||originMsg.extraFile.contains('http')){ msg.extraFile = originMsg.extraFile; }else{ msg.extraFile = UploadUtil().getFullUrl(originMsg.extraFile, originMsg.sessionId, originMsg.channelType);