From 8bc1466d9f0389c43ee5fd29f44e2e87d4770c78 Mon Sep 17 00:00:00 2001 From: Jeremy Mikola Date: Wed, 7 Aug 2013 14:23:38 -0400 Subject: [PATCH] Ensure Cursor::limit() argument is casted to an integer --- lib/Doctrine/MongoDB/Cursor.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/Doctrine/MongoDB/Cursor.php b/lib/Doctrine/MongoDB/Cursor.php index af7becda..e4301bf1 100644 --- a/lib/Doctrine/MongoDB/Cursor.php +++ b/lib/Doctrine/MongoDB/Cursor.php @@ -398,7 +398,7 @@ public function key() */ public function limit($num) { - $limit = (integer) $num; + $num = (integer) $num; $this->limit = $num; $this->mongoCursor->limit($num); return $this;