Skip to content

Commit

Permalink
Blocks: Clarify intentions for bad code
Browse files Browse the repository at this point in the history
Not my proudest work 🙂
  • Loading branch information
aduth committed Nov 30, 2017
1 parent 905799e commit 2e37145
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions blocks/library/columns/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,8 @@ registerBlockType( 'core/columns', {
edit( { attributes, setAttributes, setChildren, children, className, focus } ) {
const { columns } = attributes;

// TODO: Refactor setChildFragment to be less awful, separated, tested.

const setChildFragment = ( index ) => ( nextChildren ) => {
const fragmented = mapChildren( children, columns, identity );
const origNumChildren = fragmented[ index ].length;
Expand Down

0 comments on commit 2e37145

Please sign in to comment.