Skip to content
This repository
Browse code

simplify check

  • Loading branch information...
commit 0197700e4fd054cdb8165a01d2b152af2f85c043 1 parent 2cff671
Mark authored October 09, 2012

Showing 1 changed file with 2 additions and 2 deletions. Show diff stats Hide diff stats

  1. 4  lib/Cake/Routing/Router.php
4  lib/Cake/Routing/Router.php
@@ -633,8 +633,8 @@ public static function getRequest($current = false) {
633 633
  * @return array Parameter information
634 634
  */
635 635
 	public static function getParams($current = false) {
636  
-		if ($current && ($count = count(self::$_requests)) > 0) {
637  
-			return self::$_requests[$count - 1]->params;
  636
+		if ($current && self::$_requests) {
  637
+			return self::$_requests[count(self::$_requests) - 1]->params;
638 638
 		}
639 639
 		if (isset(self::$_requests[0])) {
640 640
 			return self::$_requests[0]->params;

0 notes on commit 0197700

Please sign in to comment.
Something went wrong with that request. Please try again.