Skip to content

Commit

Permalink
Address code review
Browse files Browse the repository at this point in the history
  • Loading branch information
kevin940726 authored and glendaviesnz committed Feb 7, 2024
1 parent 2d5b6f2 commit 2063647
Showing 1 changed file with 2 additions and 5 deletions.
7 changes: 2 additions & 5 deletions packages/block-library/src/image/image.js
Original file line number Diff line number Diff line change
Expand Up @@ -418,7 +418,6 @@ export default function Image( {
unlock( select( blockEditorStore ) );
const {
url: urlBinding,
href: hrefBinding,
alt: altBinding,
title: titleBinding,
} = metadata?.bindings || {};
Expand All @@ -430,9 +429,6 @@ export default function Image( {
getBlockBindingsSource( urlBinding?.source )
?.lockAttributesEditing === true,
lockHrefControls:
( !! hrefBinding &&
getBlockBindingsSource( hrefBinding?.source )
?.lockAttributesEditing === true ) ||
// Disable editing the link of the URL if the image is inside a pattern instance.
// This is a temporary solution until we support overriding the link on the frontend.
hasParentPattern,
Expand All @@ -454,7 +450,8 @@ export default function Image( {
<BlockControls group="block">
{ isSingleSelected &&
! isEditingImage &&
! lockHrefControls && (
! lockHrefControls &&
! lockUrlControls && (
<ImageURLInputUI
url={ href || '' }
onChangeUrl={ onSetHref }
Expand Down

0 comments on commit 2063647

Please sign in to comment.