protected function addJoinSource($joinOperator, $table, $constraint, $tableAlias = null)
    {
        $joinOperator = trim("{$joinOperator} JOIN");
        $table = Inflector::tabilize($this->quoteIdentifier(lcfirst($table)));

        // Add table alias if exists
        if (!is_null($tableAlias)) {
            $table .= " {$tableAlias}";
        }

        // Build the constraint
        if (is_array($constraint)) {
            list($firstColumn, $operator, $secondColumn) = $constraint;
            $constraint = "{$firstColumn} {$operator} {$secondColumn}";
        }

        //$table = Inflector::tabilize(lcfirst($table));
        $this->hasJoin = true;
        $this->joinSources[] = "{$joinOperator} {$table} ON {$constraint}";

        return $this;
    }