Skip to content

Commit e803264

Browse files
committed
fix:图片路径path
fix:图片路径path
1 parent 81bedaf commit e803264

File tree

1 file changed

+8
-8
lines changed

1 file changed

+8
-8
lines changed

android/src/main/java/com/netease/im/ReactCache.java

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -741,14 +741,14 @@ public static WritableMap createMessage(IMMessage item) {
741741
if (attachment instanceof ImageAttachment) {
742742
ImageAttachment imageAttachment = (ImageAttachment) attachment;
743743
if (item.getDirect() == MsgDirectionEnum.Out) {
744-
imageObj.putString("thumbPath", imageAttachment.getPathForSave());
745-
imageObj.putString("thumbPath2", imageAttachment.getPath());
744+
imageObj.putString("thumbPath2", imageAttachment.getPathForSave());
745+
imageObj.putString("thumbPath", imageAttachment.getPath());
746746
} else {
747-
imageObj.putString("thumbPath", imageAttachment.getThumbPathForSave());
748-
imageObj.putString("thumbPath2", imageAttachment.getThumbPath());
747+
imageObj.putString("thumbPath2", imageAttachment.getThumbPathForSave());
748+
imageObj.putString("thumbPath", imageAttachment.getThumbPath());
749749
}
750-
imageObj.putString("path", imageAttachment.getPathForSave());
751-
imageObj.putString("path2", imageAttachment.getPath());
750+
imageObj.putString("path2", imageAttachment.getPathForSave());
751+
imageObj.putString("path", imageAttachment.getPath());
752752
imageObj.putString("url", imageAttachment.getUrl());
753753
imageObj.putString("displayName", imageAttachment.getDisplayName());
754754
imageObj.putString("imageHeight", Integer.toString(imageAttachment.getHeight()));
@@ -771,8 +771,8 @@ public static WritableMap createMessage(IMMessage item) {
771771
if (attachment instanceof VideoAttachment) {
772772
VideoAttachment videoAttachment = (VideoAttachment) attachment;
773773
videoDic.putString("url", videoAttachment.getUrl());
774-
videoDic.putString("path", videoAttachment.getPathForSave());
775-
videoDic.putString("path2", videoAttachment.getPath());
774+
videoDic.putString("path2", videoAttachment.getPathForSave());
775+
videoDic.putString("path", videoAttachment.getPath());
776776
videoDic.putString("displayName", videoAttachment.getDisplayName());
777777
videoDic.putString("coverSizeHeight", Integer.toString(videoAttachment.getHeight()));
778778
videoDic.putString("coverSizeWidth", Integer.toString(videoAttachment.getWidth()));

0 commit comments

Comments
 (0)