hide the block for not Published IF page is node

Created on 9 May 2024, 7 months ago
Updated 10 July 2024, 4 months ago

Аctual task is to hide the block for not Published IF page is node. But not hide for notNode pages.
PHP condition:

 /*Condition if node isPublished*/
if( !($node = \Drupal::routeMatch()->getParameter('node')) || ($node instanceof \Drupal\node\NodeInterface) && $node->isPublished() ) return TRUE;
πŸ› Bug report
Status

Fixed

Version

1.0

Component

Code

Created by

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

Production build 0.71.5 2024