From 889f888c1ad40d0316d6176232f3794ce0eea126 Mon Sep 17 00:00:00 2001 From: Paul Meyrick Date: Thu, 2 Dec 2010 23:37:59 +0000 Subject: [PATCH] FIX: Revert last commit git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.4@114463 467b73ca-7a2a-4603-9d3b-597d59a354a9 --- core/model/MySQLDatabase.php | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/core/model/MySQLDatabase.php b/core/model/MySQLDatabase.php index 5a7e292c7..e5fab9857 100755 --- a/core/model/MySQLDatabase.php +++ b/core/model/MySQLDatabase.php @@ -823,11 +823,8 @@ class MySQLDatabase extends SS_Database { $records = DB::query($fullQuery); foreach($records as $record) - if(!$record['ClassName']){ - throw new Exception("ClassName can not be null, ClassName not set for ". $record['Title']); - }else{ $objects[] = new $record['ClassName']($record); - } + if(isset($objects)) $doSet = new DataObjectSet($objects); else $doSet = new DataObjectSet();