Skip to content

Commit

Permalink
Correctly exclude noncopyable attrs in duplicate
Browse files Browse the repository at this point in the history
  • Loading branch information
stacimc committed Feb 23, 2022
1 parent 32d3eca commit 6afe9e0
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion packages/block-editor/src/store/actions.js
Original file line number Diff line number Diff line change
Expand Up @@ -1181,7 +1181,9 @@ export const duplicateBlocks = ( clientIds, updateSelection = true ) => ( {
last( castArray( clientIds ) )
);
const clonedBlocks = blocks.map( ( block ) =>
cloneBlock( block, {}, null, { retainCopyAttributes: false } )
cloneBlock( block, {}, null, {
__experimentalExcludeNonCopyableAttributes: true,
} )
);
dispatch.insertBlocks(
clonedBlocks,
Expand Down

0 comments on commit 6afe9e0

Please sign in to comment.