mirror of
https://github.com/nodemailer/wildduck.git
synced 2025-01-25 01:11:54 +08:00
filter ip
This commit is contained in:
parent
87dd69152d
commit
e86ffa7c93
1 changed files with 2 additions and 2 deletions
|
@ -359,7 +359,7 @@ module.exports = (db, server, userHandler) => {
|
|||
filter.ip = ip;
|
||||
}
|
||||
|
||||
let total = await db.database.collection('authlog').countDocuments(filter);
|
||||
let total = await db.users.collection('authlog').countDocuments(filter);
|
||||
|
||||
let opts = {
|
||||
limit,
|
||||
|
@ -535,7 +535,7 @@ module.exports = (db, server, userHandler) => {
|
|||
let filter = { _id: event, user };
|
||||
let eventData;
|
||||
try {
|
||||
eventData = await db.database.collection('authlog').findOne(filter);
|
||||
eventData = await db.users.collection('authlog').findOne(filter);
|
||||
} catch (err) {
|
||||
res.json({
|
||||
error: 'MongoDB Error: ' + err.message,
|
||||
|
|
Loading…
Reference in a new issue