mirror of
https://github.com/louislam/uptime-kuma.git
synced 2025-07-24 07:21:09 -04:00
Some improvements
This commit is contained in:
parent
12237dec6e
commit
0da6e6b1fb
8 changed files with 188 additions and 71 deletions
|
@ -12,6 +12,10 @@ const { loginRateLimiter } = require("./rate-limiter");
|
|||
* @returns {Promise<Bean|null>}
|
||||
*/
|
||||
exports.login = async function (username, password) {
|
||||
if (typeof username !== "string" || typeof password !== "string") {
|
||||
return null;
|
||||
}
|
||||
|
||||
let user = await R.findOne("user", " username = ? AND active = 1 ", [
|
||||
username,
|
||||
]);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue