src/Utils/Database/Operator.php
private function exec($command)
    {
        // Adding credentials after "mysql" and "mysqldump" commands.
        $command = preg_replace(
            '/(mysql(?:dump)?)/',
            "\\1 $this->credentials",
            vsprintf($command, array_slice(func_get_args(), 1))
        );

        self::debug(['%s'], [$command]);

        return trim(shell_exec($command));
    }
private function exec($command)
    {
        // Adding credentials after "mysql" and "mysqldump" commands.
        $command = preg_replace(
            '/(mysql(?:dump)?)/',
            "\\1 $this->credentials",
            vsprintf($command, array_slice(func_get_args(), 1))
        );

        self::debug(['%s'], [$command]);

        return trim(shell_exec($command));
    }
Executes a shell command.

@param string $command
Command to execute.

@return string
Result of a shell command.