Skip to content

Commit ced6573

Browse files
author
Ben Batschelet
committed
Method getColumns() may return null
1 parent 06f2788 commit ced6573

File tree

1 file changed

+1
-1
lines changed
  • app/code/Magento/Backend/view/adminhtml/templates/widget

1 file changed

+1
-1
lines changed

app/code/Magento/Backend/view/adminhtml/templates/widget/grid.phtml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@
1919
*
2020
*/
2121
/* @var $block \Magento\Backend\Block\Widget\Grid */
22-
$numColumns = sizeof($block->getColumns());
22+
$numColumns = !is_null($block->getColumns()) ? sizeof($block->getColumns()) : 0;
2323
?>
2424
<?php if ($block->getCollection()): ?>
2525

0 commit comments

Comments
 (0)