BUGFIX Don't show search result items in MSSQLDatabase::searchEngine() that can't be viewed

This commit is contained in:
Sean Harvey 2010-02-25 02:40:26 +00:00
parent d09acc0cbe
commit 84aed0d9c3

View File

@ -1230,7 +1230,7 @@ class MSSQLDatabase extends SS_Database {
foreach($result as $row){
$row_result=DataObject::get_by_id($row['Source'], $row['ID']);
$searchResults->push($row_result);
if($row_result->canView()) $searchResults->push($row_result);
}
$searchResults->setPageLimits($start, $pageLength, $totalCount);