Fix PHPStan and PHPCS errors
This commit is contained in:
parent
f5a0225c86
commit
b49b487590
4 changed files with 12 additions and 15 deletions
|
@ -11,8 +11,9 @@ use Drupal\custom\Entity\Node\Post;
|
|||
* Implements hook_preprocess_HOOK().
|
||||
*/
|
||||
function opdavies_preprocess_page(array &$variables): void {
|
||||
/** @var \Drupal\custom\Entity\Node\Post $node */
|
||||
if (!$node = $variables['node'] ?? NULL) {
|
||||
/** @var \Drupal\custom\Entity\Node\Post|null $node */
|
||||
$node = $variables['node'] ?? NULL;
|
||||
if (!$node) {
|
||||
return;
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue