src/includes/classes/Core/Utils/Sql.php
public function quoteOrderBys(array $order_bys, string $table = ''): string
    {
        $quoted = ''; // Initialize.

        foreach ($order_bys as $_order_by => $_order) {
            if ($_order_by && is_string($_order_by)) {
                $quoted .= ','; // Always.

                if ($table) { // Table prefix?
                    $quoted .= '`'.$this->escapeName($table).'`.';
                } // If table name, add a ``. prefix.

                $quoted .= '`'.$this->escapeName($_order_by).'` '.$this->escapeOrder($_order);
            }
        } // unset($_order_by, $_order);

        return $this->c::mbTrim($quoted, ', ');
    }
public function quoteOrderBys(array $order_bys, string $table = ''): string
    {
        $quoted = ''; // Initialize.

        foreach ($order_bys as $_order_by => $_order) {
            if ($_order_by && is_string($_order_by)) {
                $quoted .= ','; // Always.

                if ($table) { // Table prefix?
                    $quoted .= '`'.$this->escapeName($table).'`.';
                } // If table name, add a ``. prefix.

                $quoted .= '`'.$this->escapeName($_order_by).'` '.$this->escapeOrder($_order);
            }
        } // unset($_order_by, $_order);

        return $this->c::mbTrim($quoted, ', ');
    }
Quotes/escapes order-bys.

@since 160422 SQL utils.

@param array  $order_bys Order-bys.
@param string $table     Table name.

@return string Quoted/escaped order-bys.