Skip to content

Commit 9cc2b6f

Browse files
committed
fix file size wrong key.
1 parent 9c3e25f commit 9cc2b6f

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

android/src/main/java/com/easemob/im_flutter_sdk/EMHelper.java

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -732,8 +732,8 @@ static EMImageMessageBody imageBodyFromJson(JSONObject json) throws JSONExceptio
732732
body.setThumbnailUrl(json.getString("thumbnailRemotePath"));
733733
body.setThumbnailSecret(json.getString("thumbnailSecret"));
734734
body.setFileLength(json.getInt("fileSize"));
735-
int width = json.getInt("height");
736-
int height = json.getInt("width");
735+
int width = json.getInt("width");
736+
int height = json.getInt("height");
737737
body.setThumbnailSize(width, height);
738738
body.setSendOriginalImage(json.getBoolean("sendOriginalImage"));
739739

@@ -770,8 +770,8 @@ static EMVideoMessageBody videoBodyFromJson(JSONObject json) throws JSONExceptio
770770
}
771771
body.setThumbnailSecret(json.getString("thumbnailSecret"));
772772
body.setFileName(json.getString("displayName"));
773-
int width = json.getInt("height");
774-
int height = json.getInt("width");
773+
int width = json.getInt("width");
774+
int height = json.getInt("height");
775775
body.setThumbnailSize(width, height);
776776
body.setRemoteUrl(json.getString("remotePath"));
777777
body.setDownloadStatus(downloadStatusFromInt(json.getInt("fileStatus")));

0 commit comments

Comments
 (0)