Fix jsdoc errors

This commit is contained in:
Chongyi Zheng 2023-09-15 18:03:58 -04:00
parent 6a2e5202e2
commit e83c8b99ac
No known key found for this signature in database
GPG key ID: E3C2287691E40E35

View file

@ -167,7 +167,7 @@ class Database {
/** /**
* Validate a database name * Validate a database name
* @param {string} dbName * @param {string} dbName Database name to validate
* @throws {Error} If the database name is invalid * @throws {Error} If the database name is invalid
* @returns {void} * @returns {void}
*/ */
@ -703,6 +703,7 @@ class Database {
/** /**
* @returns {string} Get the SQL for the current time plus a number of hours * @returns {string} Get the SQL for the current time plus a number of hours
* @throws {Error} If the database type is unknown
*/ */
static sqlHourOffset() { static sqlHourOffset() {
if (Database.dbConfig.type === "sqlite") { if (Database.dbConfig.type === "sqlite") {
@ -712,6 +713,7 @@ class Database {
} else if (Database.dbConfig.type === "postgres") { } else if (Database.dbConfig.type === "postgres") {
return "NOW() + INTERVAL '? HOUR'"; return "NOW() + INTERVAL '? HOUR'";
} }
throw new Error("Unknown database type: " + Database.dbConfig.type);
} }
} }