fixed Birthday Event, Renamed DB Colls
This commit is contained in:
@@ -39,7 +39,7 @@ async function nutsGive(interaction) {
|
||||
var amount = await interaction.options.getNumber('amount')
|
||||
|
||||
const db = mClient.db(process.env.M_DB)
|
||||
const nutsColl = db.collection('nuts')
|
||||
const nutsColl = db.collection('items_nuts')
|
||||
const yourBalance = await nutsColl.findOne({ userID: from.id })
|
||||
const theirBalance = await nutsColl.findOne({ userID: to.id })
|
||||
if (amount <= 0) {
|
||||
@@ -69,7 +69,7 @@ async function nutsCheck(interaction) {
|
||||
}
|
||||
|
||||
const db = mClient.db(process.env.M_DB)
|
||||
const nutsColl = db.collection('nuts')
|
||||
const nutsColl = db.collection('items_nuts')
|
||||
const nutsData = await nutsColl.findOne({ userID: target.id })
|
||||
|
||||
let content
|
||||
@@ -118,7 +118,7 @@ async function nutsLeaderboard(interaction) {
|
||||
.setCustomId('nuts_leaderboard_right')
|
||||
)
|
||||
const db = mClient.db(process.env.M_DB)
|
||||
const nutsColl = db.collection('nuts')
|
||||
const nutsColl = db.collection('items_nuts')
|
||||
let skip = 0
|
||||
const nutsData = await nutsColl.find({ nuts: { $gt: 0 } }).sort({ nuts: -1 }).skip(skip).limit(5).toArray()
|
||||
let fields
|
||||
@@ -139,7 +139,7 @@ async function nutsLeaderboard(interaction) {
|
||||
}
|
||||
async function nutsStats(interaction) {
|
||||
const db = mClient.db(process.env.M_DB)
|
||||
const nStatsColl = db.collection('nut-stats')
|
||||
const nStatsColl = db.collection('stats_nuts')
|
||||
const stats = await nStatsColl.find({}).sort({ amount: 1 }).toArray()
|
||||
let nutMin = {
|
||||
count: 0,
|
||||
@@ -188,7 +188,7 @@ async function nutsStats(interaction) {
|
||||
}
|
||||
async function nutsCooldown(interaction) {
|
||||
const db = mClient.db(process.env.M_DB)
|
||||
const nutsColl = db.collection('cooldown')
|
||||
const nutsColl = db.collection('items_cooldowns')
|
||||
const cooldown = await nutsColl.findOne({ userID: interaction.user.id })
|
||||
|
||||
let content = `Du kannst wieder nussen! :)`
|
||||
@@ -213,8 +213,8 @@ async function nutsCooldown(interaction) {
|
||||
}
|
||||
async function nutsNut(interaction) {
|
||||
const db = mClient.db(process.env.M_DB)
|
||||
const nutsColl = db.collection('nuts')
|
||||
const cdColl = db.collection('cooldown')
|
||||
const nutsColl = db.collection('items_nuts')
|
||||
const cdColl = db.collection('items_cooldowns')
|
||||
|
||||
const cdData = await cdColl.findOne({ userID: interaction.user.id })
|
||||
const embed = new EmbedBuilder()
|
||||
|
||||
Reference in New Issue
Block a user