mirror of
https://github.com/louislam/uptime-kuma.git
synced 2024-12-18 20:24:36 -05:00
🐛 fix: lint warnings & errors (#3862)
* fix: lint warnings & errors * fix: lint warning * fix: lint warnings * Update user.js * Update util-server.js * Update server/util-server.js Co-authored-by: Nelson Chan <3271800+chakflying@users.noreply.github.com> * Update server/model/user.js Co-authored-by: Nelson Chan <3271800+chakflying@users.noreply.github.com> --------- Co-authored-by: Nelson Chan <3271800+chakflying@users.noreply.github.com>
This commit is contained in:
parent
9d5cf5ea03
commit
67d0ef571d
@ -31,9 +31,9 @@ class User extends BeanModel {
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* Create a new JWT for a user
|
* Create a new JWT for a user
|
||||||
* @param {User} user
|
* @param {User} user The User to create a JsonWebToken for
|
||||||
* @param {string} jwtSecret
|
* @param {string} jwtSecret The key used to sign the JsonWebToken
|
||||||
* @return {string}
|
* @returns {string} the JsonWebToken as a string
|
||||||
*/
|
*/
|
||||||
static createJWT(user, jwtSecret) {
|
static createJWT(user, jwtSecret) {
|
||||||
return jwt.sign({
|
return jwt.sign({
|
||||||
|
@ -81,7 +81,7 @@ const Monitor = require("./model/monitor");
|
|||||||
const User = require("./model/user");
|
const User = require("./model/user");
|
||||||
|
|
||||||
log.debug("server", "Importing Settings");
|
log.debug("server", "Importing Settings");
|
||||||
const { getSettings, setSettings, setting, initJWTSecret, checkLogin, startUnitTest, FBSD, doubleCheckPassword, startE2eTests, shake256, SHAKE256_LENGTH, allowDevAllOrigin,
|
const { getSettings, setSettings, setting, initJWTSecret, checkLogin, FBSD, doubleCheckPassword, startE2eTests, shake256, SHAKE256_LENGTH, allowDevAllOrigin,
|
||||||
} = require("./util-server");
|
} = require("./util-server");
|
||||||
|
|
||||||
log.debug("server", "Importing Notification");
|
log.debug("server", "Importing Notification");
|
||||||
|
@ -1066,10 +1066,9 @@ module.exports.grpcQuery = async (options) => {
|
|||||||
module.exports.SHAKE256_LENGTH = 16;
|
module.exports.SHAKE256_LENGTH = 16;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
* @param {string} data The data to be hashed
|
||||||
* @param {string} data
|
* @param {number} len Output length of the hash
|
||||||
* @param {number} len
|
* @returns {string} The hashed data in hex format
|
||||||
* @return {string}
|
|
||||||
*/
|
*/
|
||||||
module.exports.shake256 = (data, len) => {
|
module.exports.shake256 = (data, len) => {
|
||||||
if (!data) {
|
if (!data) {
|
||||||
|
Loading…
Reference in New Issue
Block a user