Merge pull request #284 from mandrew/patch-1

FIX: updateCMSFields not accepting var by reference
This commit is contained in:
Ingo Schommer 2013-02-04 04:58:28 -08:00
commit 1525684e68

View File

@ -9,7 +9,7 @@ class SiteTreeFileExtension extends DataExtension {
'BackLinkTracking' => 'SiteTree' 'BackLinkTracking' => 'SiteTree'
); );
public function updateCMSFields(FieldList $fields) { public function updateCMSFields(FieldList &$fields) {
$fields->insertAfter(new ReadonlyField('BackLinkCount', $fields->insertAfter(new ReadonlyField('BackLinkCount',
_t('AssetTableField.BACKLINKCOUNT', 'Used on:'), _t('AssetTableField.BACKLINKCOUNT', 'Used on:'),
$this->BackLinkTracking()->Count() . ' ' . _t('AssetTableField.PAGES', 'page(s)')), $this->BackLinkTracking()->Count() . ' ' . _t('AssetTableField.PAGES', 'page(s)')),