From 538a14338c2b7244229d766a591dff6703bdbd6d Mon Sep 17 00:00:00 2001 From: Dragory <2606411+Dragory@users.noreply.github.com> Date: Fri, 14 Aug 2020 01:01:40 +0300 Subject: [PATCH] Update mysqlOptions schema --- src/data/cfg.jsdoc.js | 14 +++++++++----- src/data/cfg.schema.json | 8 +++++--- 2 files changed, 14 insertions(+), 8 deletions(-) diff --git a/src/data/cfg.jsdoc.js b/src/data/cfg.jsdoc.js index 26eb805..49a21f3 100644 --- a/src/data/cfg.jsdoc.js +++ b/src/data/cfg.jsdoc.js @@ -47,11 +47,15 @@ * @property {*} [commandAliases] * @property {number} [port=8890] * @property {string} [url] - * @property {string} [dbDir] - * @property {object} [knex] - * @property {string} [logDir] * @property {array} [extraIntents=[]] * @property {*} [dbType="sqlite"] - * @property {*} [sqliteOptions] - * @property {*} [mysqlOptions] + * @property {object} [sqliteOptions] + * @property {string} sqliteOptions.filename + * @property {object} [mysqlOptions] + * @property {string} mysqlOptions.host + * @property {number} mysqlOptions.port + * @property {string} mysqlOptions.user + * @property {string} mysqlOptions.password + * @property {string} mysqlOptions.database + * @property {string} [mysqlOptions.timezone] */ diff --git a/src/data/cfg.schema.json b/src/data/cfg.schema.json index 4fa58a1..198c87a 100644 --- a/src/data/cfg.schema.json +++ b/src/data/cfg.schema.json @@ -282,10 +282,12 @@ "type": "object", "properties": { "host": { - "type": "string" + "type": "string", + "default": "localhost" }, "port": { - "type": "number" + "type": "number", + "default": "3306" }, "user": { "type": "string" @@ -300,7 +302,7 @@ "type": "string" } }, - "required": ["user", "password", "database"] + "required": ["host", "port", "user", "password", "database"] } }, "allOf": [