Merge pull request #256 from madmatt/pulls/fix-null-dataquery

Fix error when dataQuery is a null object
This commit is contained in:
Daniel Hensby 2016-07-18 11:39:47 +01:00 committed by GitHub
commit b8667fb933

View File

@ -33,7 +33,7 @@ class SiteTreeSubsites extends DataExtension
if (Subsite::$disable_subsite_filter) { if (Subsite::$disable_subsite_filter) {
return; return;
} }
if ($dataQuery->getQueryParam('Subsite.filter') === false) { if ($dataQuery && $dataQuery->getQueryParam('Subsite.filter') === false) {
return; return;
} }