From c658dc2e6179f748804ce7657cfed671b84a3aaa Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Dariusz=20G=C3=B3recki?= Date: Mon, 14 Feb 2011 12:36:57 +0100 Subject: [PATCH] Changed returned value form EMongoDocument::search() method to match Yii default behavior Now search() method returns DataProvider instead of $this, that was incostintent with standard Yii AR --- EMongoDocument.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/EMongoDocument.php b/EMongoDocument.php index 216423df..f4e38a19 100644 --- a/EMongoDocument.php +++ b/EMongoDocument.php @@ -1281,7 +1281,7 @@ public function search($caseSensitive = false) $this->setDbCriteria($criteria); - return $this; + return new EMongoDocumentDataProvider($this); } /**