Skip to content

Commit 0d8a990

Browse files
committed
Merge remote-tracking branch 'origin/MAGETWO-58370' into public-prs2
2 parents e0214e1 + 5ccb1bb commit 0d8a990

File tree

1 file changed

+4
-1
lines changed
  • lib/internal/Magento/Framework/View/Layout/Generator

1 file changed

+4
-1
lines changed

lib/internal/Magento/Framework/View/Layout/Generator/Block.php

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -261,7 +261,10 @@ protected function getBlockInstance($block, array $arguments = [])
261261
}
262262
if (!$block instanceof \Magento\Framework\View\Element\AbstractBlock) {
263263
throw new \Magento\Framework\Exception\LocalizedException(
264-
new \Magento\Framework\Phrase('Invalid block type: %1', [$block]),
264+
new \Magento\Framework\Phrase(
265+
'Invalid block type: %1',
266+
[is_object($block) ? get_class($block) : (string) $block]
267+
),
265268
$e
266269
);
267270
}

0 commit comments

Comments
 (0)