mirror of
https://github.com/vrana/adminer.git
synced 2025-08-08 15:47:00 +02:00
CockroachDB: Do not use version number when linking docs
This commit is contained in:
@@ -2,9 +2,9 @@
|
||||
|
||||
/** Load syntax highlighting
|
||||
* @param string first three characters of database system version
|
||||
* @param [boolean]
|
||||
* @param [string]
|
||||
*/
|
||||
function bodyLoad(version, maria) {
|
||||
function syntaxHighlighting(version, vendor) {
|
||||
if (window.jush) {
|
||||
jush.create_links = ' target="_blank" rel="noreferrer noopener"';
|
||||
if (version) {
|
||||
@@ -13,7 +13,7 @@ function bodyLoad(version, maria) {
|
||||
if (typeof obj[key] != 'string') {
|
||||
obj = obj[key];
|
||||
key = 0;
|
||||
if (maria) {
|
||||
if (vendor == 'maria') {
|
||||
for (var i = 1; i < obj.length; i++) {
|
||||
obj[i] = obj[i]
|
||||
.replace('.html', '/')
|
||||
@@ -29,10 +29,12 @@ function bodyLoad(version, maria) {
|
||||
}
|
||||
}
|
||||
|
||||
obj[key] = (maria ? obj[key].replace('dev.mysql.com/doc/mysql', 'mariadb.com/kb') : obj[key]) // MariaDB
|
||||
obj[key] = (vendor == 'maria' ? obj[key].replace('dev.mysql.com/doc/mysql', 'mariadb.com/kb') : obj[key]) // MariaDB
|
||||
.replace('/doc/mysql', '/doc/refman/' + version) // MySQL
|
||||
.replace('/docs/current', '/docs/' + version) // PostgreSQL
|
||||
;
|
||||
if (vendor != 'cockroach') {
|
||||
obj[key] = obj[key].replace('/docs/current', '/docs/' + version); // PostgreSQL
|
||||
}
|
||||
}
|
||||
}
|
||||
if (window.jushLinks) {
|
||||
|
Reference in New Issue
Block a user