Skip to content

Commit faa3f65

Browse files
fix image upload to gallery block
1 parent 70fa945 commit faa3f65

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

assets/src/media/modal/messageHandler.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -150,7 +150,7 @@ class MessageHandler {
150150
attachment.fetch().then( ( r ) => {
151151
attachmentsQueue.push( r );
152152

153-
if ( idx === result.data.length - 1 ) {
153+
if ( attachmentsQueue.length === result.data.length ) {
154154
this.sendMessage({ status: 'done' });
155155

156156
// Add the attachments to the selection.

0 commit comments

Comments
 (0)