Browse Source

refactor the query compiler.

Taylor Otwell 13 years ago
parent
commit
0700910270
1 changed files with 3 additions and 12 deletions
  1. 3 12
      laravel/db/compiler.php

+ 3 - 12
laravel/db/compiler.php

@@ -12,20 +12,11 @@ class Compiler {
 	{
 		$sql = $query->select.' '.$query->from.' '.$query->where;
 
-		if ( ! is_null($query->order))
-		{
-			$sql .= ' '.$query->order;
-		}
+		if ( ! is_null($query->order)) $sql .= ' '.$query->order;
 
-		if ( ! is_null($query->limit))
-		{
-			$sql .= ' '.$query->limit;
-		}
+		if ( ! is_null($query->limit)) $sql .= ' '.$query->limit;
 
-		if ( ! is_null($query->offset))
-		{
-			$sql .= ' '.$query->offset;
-		}
+		if ( ! is_null($query->offset)) $sql .= ' '.$query->offset;
 
 		return $sql;
 	}