mirror of
https://github.com/silverstripe/silverstripe-cms
synced 2024-10-22 08:05:56 +02:00
ENHANCEMENT: Remove unused $controller from lambda function
This commit is contained in:
parent
9cb96bfc52
commit
2bbc280ce6
@ -1674,9 +1674,8 @@ class CMSMain extends LeftAndMain implements CurrentPageIdentifier, PermissionPr
|
|||||||
'getTreeTitle' => 'HTMLFragment'
|
'getTreeTitle' => 'HTMLFragment'
|
||||||
));
|
));
|
||||||
|
|
||||||
$controller = $this;
|
|
||||||
$columns->setFieldFormatting(array(
|
$columns->setFieldFormatting(array(
|
||||||
'listChildrenLink' => function ($value, &$item) use ($controller) {
|
'listChildrenLink' => function ($value, &$item) {
|
||||||
/** @var SiteTree $item */
|
/** @var SiteTree $item */
|
||||||
$num = $item ? $item->numChildren() : null;
|
$num = $item ? $item->numChildren() : null;
|
||||||
if ($num) {
|
if ($num) {
|
||||||
@ -1687,7 +1686,7 @@ class CMSMain extends LeftAndMain implements CurrentPageIdentifier, PermissionPr
|
|||||||
);
|
);
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
'getTreeTitle' => function ($value, &$item) use ($controller) {
|
'getTreeTitle' => function ($value, &$item) {
|
||||||
$title = sprintf(
|
$title = sprintf(
|
||||||
'<a class="action-detail" href="%s">%s</a>',
|
'<a class="action-detail" href="%s">%s</a>',
|
||||||
Controller::join_links(
|
Controller::join_links(
|
||||||
|
Loading…
Reference in New Issue
Block a user