mirror of
https://github.com/silverstripe/silverstripe-subsites
synced 2024-06-26 14:39:19 +02:00
Fixed bug with deleting in CMS
This commit is contained in:
parent
c301044be9
commit
956e2402df
|
@ -54,6 +54,8 @@ class SiteTreeSubsites extends DataObjectDecorator {
|
|||
|
||||
// The foreach is an ugly way of getting the first key :-)
|
||||
foreach($query->from as $tableName => $info) {
|
||||
// The tableName should be SiteTree or SiteTree_Live...
|
||||
if(strpos($tableName,'SiteTree') === false) break;
|
||||
$query->where[] = "`$tableName`.SubsiteID IN ($subsiteID)";
|
||||
break;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue
Block a user