MINOR: can_edit_multiple() should return false, not 0, for permission failure. (from r92192)

git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.4@96744 467b73ca-7a2a-4603-9d3b-597d59a354a9
This commit is contained in:
Sam Minnee 2010-01-12 23:24:44 +00:00
parent 5930458997
commit 14aa0b6bff

View File

@ -974,8 +974,8 @@ class SiteTree extends DataObject implements PermissionProvider,i18nEntityProvid
foreach(array('Stage', 'Live') as $stage) {
// Start by filling the array with the pages that actually exist
$table = ($stage=='Stage') ? "SiteTree" : "SiteTree_$stage";
$result = DB::query("SELECT \"ID\",0 FROM \"$table\"
WHERE \"ID\" IN (".implode(", ", $ids).")")->map();
$result = array_fill_keys(DB::query("SELECT \"ID\" FROM \"$table\"
WHERE \"ID\" IN (".implode(", ", $ids).")")->column(), false);
// Get the uninherited permissions
$uninheritedPermissions = Versioned::get_by_stage("SiteTree", $stage, "(\"CanEditType\" = 'LoggedInUsers' OR