forked from Galactic/galactic-bot
bugfix to history
This commit is contained in:
parent
52d3b141c4
commit
85448f9616
@ -48,7 +48,6 @@ class UserWrapper {
|
||||
let points = p;
|
||||
// Imported cases may have false or null
|
||||
if (typeof points !== 'number') points = 0;
|
||||
console.log(points);
|
||||
if (expiration > 0) {
|
||||
index.expirations.push({ points, expiration, id });
|
||||
} else {
|
||||
|
@ -129,7 +129,7 @@ class HistoryCommand extends SlashCommand {
|
||||
const [result] = await infractions.aggregate([{
|
||||
$match: {
|
||||
...query,
|
||||
$or: [{ expiration: { $gt: Date.now() } }, { expiration: null }],
|
||||
$or: [{ expiration: { $gt: Date.now() } }, { expiration: null }, { expiration: 0 }],
|
||||
resolved: false
|
||||
}
|
||||
}, {
|
||||
|
Loading…
Reference in New Issue
Block a user