From bb569eec2ad7b602fad60ce68b8e6d29f8ecd4eb Mon Sep 17 00:00:00 2001 From: Riad Benguella Date: Thu, 4 Nov 2021 16:17:32 +0100 Subject: [PATCH] Fix JS error when the padding is not a correct object --- packages/block-editor/src/layouts/flow.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/packages/block-editor/src/layouts/flow.js b/packages/block-editor/src/layouts/flow.js index ba83fcdb3b52c2..d0ebcada8f468f 100644 --- a/packages/block-editor/src/layouts/flow.js +++ b/packages/block-editor/src/layouts/flow.js @@ -133,8 +133,8 @@ export default { ${ appendSelectors( selector, '> [data-align="full"]' ) } { max-width: none; - margin-left: calc( -1 * ${ padding.left || 0 } ) !important; - margin-right: calc( -1 * ${ padding.right || 0 } ) !important; + margin-left: calc( -1 * ${ padding?.left || 0 } ) !important; + margin-right: calc( -1 * ${ padding?.right || 0 } ) !important; } ` : '';