Skip to content

Commit df3d048

Browse files
committed
fix: image uploads issue in iOS devices
refactor: remove unwanted console.log statements
1 parent 56c7875 commit df3d048

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

package/src/contexts/messageInputContext/MessageInputContext.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -961,7 +961,7 @@ export const MessageInputProvider = <
961961
response = await value.doImageUploadRequest(file, channel);
962962
} else if (compressedUri && channel) {
963963
if (value.sendImageAsync) {
964-
channel.sendImage(compressedUri, undefined, contentType).then((res) => {
964+
channel.sendImage(compressedUri, file.filename, contentType).then((res) => {
965965
if (asyncIds.includes(id)) {
966966
// Evaluates to true if user hit send before image successfully uploaded
967967
setAsyncUploads((prevAsyncUploads) => {
@@ -980,7 +980,7 @@ export const MessageInputProvider = <
980980
}
981981
});
982982
} else {
983-
response = await channel.sendImage(compressedUri, undefined, contentType);
983+
response = await channel.sendImage(compressedUri, file.filename, contentType);
984984
}
985985
}
986986

0 commit comments

Comments
 (0)