public function compileDelete(Builder $query) {
		$table = $this->wrap($query->from[0]);
	
		$where = $this->compileWheres($query);
	
		if (isset($query->joins)) {
			$joins = ' '.$this->compileJoins($query, $query->joins);

			$sql = trim("delete $table from {$table}{$joins} $where");
		
		} else {
			$sql = trim("delete from $table $where");
			
			if (isset($query->orders)) {
				$sql .= ' '.$this->compileOrders($query, $query->orders);
			}
			
			if (isset($query->limit)) {
				$sql .= ' '.$this->compileLimit($query, $query->limit);
			}
		}
		return $sql;
		
		
	}