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;
|
let points = p;
|
||||||
// Imported cases may have false or null
|
// Imported cases may have false or null
|
||||||
if (typeof points !== 'number') points = 0;
|
if (typeof points !== 'number') points = 0;
|
||||||
console.log(points);
|
|
||||||
if (expiration > 0) {
|
if (expiration > 0) {
|
||||||
index.expirations.push({ points, expiration, id });
|
index.expirations.push({ points, expiration, id });
|
||||||
} else {
|
} else {
|
||||||
|
@ -129,7 +129,7 @@ class HistoryCommand extends SlashCommand {
|
|||||||
const [result] = await infractions.aggregate([{
|
const [result] = await infractions.aggregate([{
|
||||||
$match: {
|
$match: {
|
||||||
...query,
|
...query,
|
||||||
$or: [{ expiration: { $gt: Date.now() } }, { expiration: null }],
|
$or: [{ expiration: { $gt: Date.now() } }, { expiration: null }, { expiration: 0 }],
|
||||||
resolved: false
|
resolved: false
|
||||||
}
|
}
|
||||||
}, {
|
}, {
|
||||||
|
Loading…
Reference in New Issue
Block a user