update
This commit is contained in:
parent
fe5985c665
commit
da1866915b
17
client.js
17
client.js
@ -24,21 +24,6 @@ client.on("ready", () => {
|
|||||||
client.user.setStatus('dnd')
|
client.user.setStatus('dnd')
|
||||||
});
|
});
|
||||||
|
|
||||||
// client.once("ready", () => {
|
|
||||||
// // ensure that the bot stats document exists
|
|
||||||
// const wolfcount = new Wolfcount({
|
|
||||||
// count: 0,
|
|
||||||
// validation: "count"
|
|
||||||
// });
|
|
||||||
|
|
||||||
// wolfcount.save().then(() => {
|
|
||||||
// console.log('Count document saved successfully into the database!');
|
|
||||||
// }).catch(err => {
|
|
||||||
// console.log('Error while saving the count document', err);
|
|
||||||
// });
|
|
||||||
|
|
||||||
// });
|
|
||||||
|
|
||||||
// Error handling
|
// Error handling
|
||||||
client.on("error", (error) => {
|
client.on("error", (error) => {
|
||||||
console.error("Something went wrong:", error);
|
console.error("Something went wrong:", error);
|
||||||
@ -48,7 +33,7 @@ client.on("error", (error) => {
|
|||||||
const wolfChars = ['w', 'o', 'l', 'f'];
|
const wolfChars = ['w', 'o', 'l', 'f'];
|
||||||
|
|
||||||
// Find a document by validation
|
// Find a document by validation
|
||||||
Wolfcount.findOne({ validation: 'count' }).then((countdocument) => {
|
Wolfcount.findOne({ validation: 'wolfcount' }).then((countdocument) => {
|
||||||
console.log(countdocument);
|
console.log(countdocument);
|
||||||
}).catch((error) => {
|
}).catch((error) => {
|
||||||
console.error(error);
|
console.error(error);
|
||||||
|
Loading…
Reference in New Issue
Block a user