#development
1 messages ยท Page 1883 of 1
jenious
jeSus
sus
your status looks sus
yes
Timotei roiko
kkkkkk
const deletionLog = fetchedLogs.entries.first();
if (!deletionLog) return;
const { executor, target } = deletionLog;
${message.content}
The message.content not working
Where is message defined
module.exports = {
name: 'messageDelete',
async execute(client, message) {
In embed
ok. i learned the basics of v13
Show where you are making the embed
now imma have to import code with confidence
const DeletedLog = new Discord.MessageEmbed()
.setDescription(`Member: ${target.tag}\nExecutor: ${executor.tag}\nIn: ${message.channel}\n\n**Content:** ${message.content}`)
Can you just show the whole file again and not send parts of it?
It's happened when the executor if not the message.author
Also try logging message.content
Why is the message.content floating in the middle of nowhere?
Bro
Remove that
That happened when the member who deleted the message is not the message.author
that's all
My on message event does not work on the mobile app
is there any way to fix this?
no errors
works completely fine on pc
but does not respond when used on the mobile app
its not only for me
contact the devs
it does not work anyone who uses it from mobile
My bal command is not working
It was working yesterday
Today when I did p!beg
And work command
It is not being added in my bal
can't help you if you don't show us any code
wait I'm showing
let user =
message.mentions.members.first() ||
message.guild.members.cache.get(args[0]) ||
message.guild.members.cache.find(
r =>
r.user.username.toLowerCase() === args.join(" ").toLocaleLowerCase()
) ||
message.guild.members.cache.find(
r => r.displayName.toLowerCase() === args.join(" ").toLocaleLowerCase()
) ||
message.member;
let bal = db.fetch(`money_${user.id}`);
if (bal === null) bal = 0;
let bank = await db.fetch(`bank_${user.user.id}`);
if (bank === null) bank = 0;
let Total = bal + bank
if (user) {
let moneyEmbed = new MessageEmbed()
.setColor("BLUE")
.setDescription(
`**${user.user.username}'s Balance**\n**Cash:** ${bal} Hay-cash\n**Bank:** ${bank}\n**Total:** ${Total}`
);
message.channel.send(moneyEmbed);
here it is
this is the basic code
and yea
let MessageArray = message.content.split(' ');
let args = MessageArray.slice(1)
```
what is the difference between mongodb and mongoose?
but mongodb is faster and easier
not related to your problem, but why are you mixing locale lowercase with lowercase
coz it was working fine yesterday
๐ข
now i've removed it....
still the same
what are deez funny words
mongo hosting is too expensive
why cant my bot embed messages? if i make the bot admin it works fine.. the permissions for its role.. looks fine.. i get discord.ext.commands.errors.CommandInvokeError: Command raised an exception: Forbidden: 403 Forbidden (error code: 50013): Missing Permissions when i try to embed. any help?
The channel in which you are running the bot, is it having the permissions to send messages?
Without administrator
oh right let me check that
Cool
I'm trying to do a command disable trough database:
code of messageCreate event: https://srcb.in/EkTBNvePdR
but it gives me the error
if(controllo.Cmds.includes(command.name)) return message.channel.send(`Questo comando รจ stato disabilitato dagli admin`)
^
ReferenceError: command is not defined```
help in fixing that, pls?
try to rename command to commands ig?
you didn't close your ban method
no err now, but still doesnt work
when i run mongoosemodel.save, where is it saved?
and how do i migrate my existing bs code to mongoose?
will this work?
mongo.db("botData").collection("guilds").insertOne({
guildId: context.guild.id,
users: {
[context.user.id]: {
xp: 0,
level: 0,
xpNeeded: 20
}
}
});
const userSchema = new Mongoose.Schema({
guildId: String,
users: {
String: {
xp: Number,
level: Number,
xpNeeded: Number
}
}
});
const User = Mongoose.model("User", userSchema);
const user = new User({
guildId: context.guild.id,
users: {
[context.user.id]: {
xp: 0,
level: 0,
xpNeeded: 20
}
}
});
user.save(console.error);
i do NOT want to fuck my database AGAIN i don't want to try it and see
now i have to replace all .findOneAndUpdate to something to update it
find /path/to/files -type f -exec sed -i 's/.findOneAndUpdate/new method/g' {} \;
free stackoverflow searching for you
replaces every .findOneAndUpdate with new method
i recommend keeping a backup before doing that
what would happen if i kept the version with .findOneAndUpdate
(probably deprecate it)
on a future version u will get a type err and now depre.. notes
cont data = await model.findOne({id:`11`}) data.prop= 100; await data.save()
question: should I keep an array of MemberSchema with id properties on the guild's members property or do I put it as a MongooseMap of memberId: data key values?
well its up to you, if the data is cached then a map is good. since you can just .set or .get
another question: do i need the schema or do i just make the model with the schema and use that
do i do mongoose.model() everytime or just once
and then pass the model to every command?
idk why im being worried
i switched to mongodb for a while now, but i do it like this when i use mongoose
oh i misread the docs
a model is NOT a document but can be used to create a document
yes
@sacred aurora confusion:
I have a Guild document:
const guild = await Models.Guild.findOne({ id: "Gotta make you understand" })
And a Member document:
const member = new Models.Member({ id: "Never gonna give you up" });
How do I push this to the guild document's members property?
global.Schemas = require("./misc/schemas.js");
global.Models = {
Guild: mongoose.model("Guild", Schemas.Guild),
Member: mongoose.model("Member", Schemas.Member)
};
its in a different collection then
but i want to save it as property of a guild
then just use one schema
or
guild.members.push(member);
await guild.save();
ugh i don't get the idea
oop typo
thats good way to globally share things

i got the idea from flazepe
members is array?
i put my models and other stuff instead the client class
thanks for asking flaz how to globally share things
yes
if you do it like this, then there's a high chance of duplicate
should I use a map?
cuz then I can use .set
object works fine
yeah you could use map aswell
time to change schemas
if u're using object then u can do like
guild.updateOne({guildId: guildId}, {[`members.${memberId}`]: data})
maybe
const
Member = new mongoose.Schema({
id: String,
xp: {
type: Number,
default: 0
},
level: {
type: Number,
default: 0
},
xpNeeded: {
type: Number,
default: 0
},
bookmarks: {
type: Map,
of: Bookmark
}
}),
Guild = new mongoose.Schema({
id: String,
members: {
type: Map,
of: Member
}
});
this good?
dunno if that work
thats a schema not a model

yes
u need a model to do stuff with it
i was sending my schemas...
global.Schemas = require("./misc/schemas.js");
global.Models = {
Guild: mongoose.model("Guild", Schemas.Guild),
Member: mongoose.model("Member", Schemas.Member)
};
ah kek
what im trying to do is using .updateOne instead of .findOneAndUpdate
but idk how to get the updated version of that document like for .findOneAndUpdate
.findOneAndUpdate(
{
id: "911"
},
{
iq: 0,
},
{
new: true,
}
)
sorry abt the formatting
const defaultMemberData = member => {
return {
[member.id]: defaultXpData
};
};
const defaultXpData = {
xp: 0,
level: 1,
xpNeeded: 20
};
let guildData = Models.Guild.findOne({ id: message.guild.id });
if (!guildData) {
const guild = new Models.Guild({
id: message.guild.id,
members: defaultMemberData(message.author)
});
await guild.save();
} else if (!guildData[message.author.id]) {
guildData.members.set(message.author.id, defaultXpData);
}
@sacred aurora
member.id is a string btw
is that a map?
yeah
but the defaultMemberData return an object
or mongoose automatically convert it
?
lmao
also i made a typo
await the findOne
yeah
if (!guild) {
guild = new Models.Guild({
id: message.guild.id,
members: defaultMemberData(message.author)
});
await guild.save();
} else if (!guild.members.get(message.author.id)) {
guild.members.set(message.author.id, defaultXpData);
await guild.save();
}
please forgive the intensely bad formatting
that'll do it
need to do some more tweaks and then i'll test if it works
alright how do I save
imagine forgetting a basic method
Does someone know how to change permissions for a channel with discord.js v13?
channel.overWrite(role, {permission}) doesn't work for me
what save is this
guild = guild || await Models.Guild.findOne({ id: message.guild.id });
const memberData = guild.members.get(message.author.id);
memberData.xp += Math.floor(Math.random() * 5);
if (memberData.xp >= memberData.xpNeeded) {
memberData.rank++;
memberData.xpNeeded += Math.floor(memberData.xpNeeded * 1.10);
}
guild.members.set(message.author.id, memberData);
await guild.save();
๐ pls work on the first try
this?
remind me why i am a programmer
global.mongoose = mongooose;
ReferenceError: mongooose is not defined
triple o?
its because of this
do i just remove the member model?
ok
yep, thanks
np
hello how can i do this pls ?
?
this what?
I'm trying to block commands trough database
this is my message event: https://srcb.in/5yeXAciO02
the error is: ```C:\Users\Utente\Desktop\novabotv13\events\messageCreate.js:24
if(controllo.command.includes(commands.name)) return message.channel.send(Questo comando รจ stato disabilitato dagli admin)
^
TypeError: Cannot read properties of undefined (reading 'includes')
at Client.<anonymous> (C:\Users\Utente\Desktop\novabotv13\events\messageCreate.js:24:30)
at processTicksAndRejections (node:internal/process/task_queues:96:5)```
the change in the database works, but the check doesnt work ๐ฆ
controllo.command is undefined
how are u retrieving it?
500k+ data of? Depends on WHAT you're storing
and how
And how frequently too
and if you have a cache layer
I guess it depends on the hardware the mongodb cluster is running on too.
pretty much, its impossible to say in hypotheticals.
How to improve it?
https://github.com/eyal282/Chess-ELO-Discord-Bot
No only if you don't have much querys and documents are cached
honestly, thinking of moving to serverless databases just out of laziness.
And if your bot has 100k guilds,you should have a powerful vps to use mongodb locally
don't push node_modules to git
Why?
they make the repo gigantic. You can install it from npm when you clone
plus they wont work on different systems if they have any native code
:(
git rm -rf node_modules --cached
Will replit.com listen to my .gitignore?
Actually I don't need to rush deleting node_modules, I'll wait for the top.gg verify, then I'll figure it out
import discord
import os
client = discord.Client()
@client.event
async def on_ready():
print ('Hi I am ur trusty empire bot')
@client.event
asnyc def on_message(message):
if message.author == client.user:
return
if message.content.startswith('c!test'):
await message.channel.send('Tested!')
Code ^ ^
asnyc def on_message(message):
^
SyntaxError: invalid syntax
๎บง
Error ^
Line 11 is this:
asnyc def on_message(message):
This is my Friend's code, not mine.
asnyc
it needs to be async
pretty sure the bug fix is the same on both py and js ๐
Now says line 14 (the asnyc def on_message(message): )
import discord
import os
os.system("pip install discord_components")
from discord_components import *
client = discord.Client()
@client.event
async def on_ready():
print ('Hi I am ur trusty empire bot')
on @client.event
asnyc def on_message(message):
if message.author == client.user:
return
if message.content.startswith('c!test'):
await message.channel.send('Tested!')
Like 14.
doesnt seem like they fixed the typo
What typo?
File "main.py", line 14
asnyc def on_message(message):
^
SyntaxError: invalid syntax
async is spelt async, not asnyc
Wha-
ok
But ther eis no difference between async and async
File "main.py", line 19
if message.content.startswith('c!test'):
^
IndentationError: unindent does not match any outer indentation level
That Line (19 and 20)
if message.content.startswith('c!test'):
await message.channel.send('Tested!')
async and asnyc is the same thing?
Woo, look above that message
thats in plain English.
your indentations are wrong.
https://www.geeksforgeeks.org/indentation-in-python/
I dont code PY, so i am confused
if you add a caching layer, and you are optimized with your queries it shouldn't have too many issues.
And, he cannot get on topgg server haha
py code doesnt use brackets like JS, it uses tabs/spaces instead of brackets.
if you use tabs for example, and try to indent with a space, py errors.
as its not complying with the standard
SO confused.......
you should really tell whoever your helping to use the py support server if they cant use top.gg, or to use some other method of help.
as using a middle man just wastes everyones time
They don't got a Number on discord
So, no tpogg and no PY lol
discord isnt the only place to get help with programming
shouldn't be an issue then
Fixing memory leaks sucks
although I suspect nosql is not the most optimal choice for that matter
My bot created every command 2 times. Dont know how it happened, so here I registerd my commands:
// await client.guilds.cache.get(guildId)?.commands.set(data)
// await client.application?.commands.set(data);
client.guilds.cache.forEach(async server => {
await client.guilds.cache.get(server.id)?.commands.set(data)
});
How can I clear the second / dauble commands?
Yoy might have made both global and guild commands
So just global commands?
this?
await client.application?.commands.set(data);
And how can I delete now the second slash commands?
...he ignored what I highlighted
what is so interesting there?
if you need an id, just use
client.guilds.cache.forEach(async server => {
await client.guilds.cache.get(server.id).id
});
super easy.
kek
red - you're getting client.guilds.cache from inside a client.guilds.cache foreach loop
orange - await in a cache operation?
green - you already have the server object, why get it again?
bonus - foreach...why not a normal for-each?
?
and this
this sum what he's doing very well
https://acegif.com/wp-content/uploads/2021/04/bugs-bunny-85.gif
Can this change a value of a property?
'use-strict'; // Strict JS File
require('dotenv').config(); // Requiring the ".env" file to access the passwords that will allow us to use to be able to fetch from the Dictionary API.
const settings = require('../settings/settings.js');
(async () => {
settings.find(val => val.id.toLowerCase() === "translationlanguage").language = 'arabic';
})();
module.exports = [
{
id: 'translationlanguage',
description: 'Please mention the translation language you want to tralsnate your word to.',
language: 'Arabic'
},
];
๐คฃ
Anyone?
yes
hey! I have this writing to txt function: js fs.appendFile("./wallets.txt.json", (`User: ${message.author.tag} Wallet: ${args[0][1]}`), (err) => { if (err) console.log(err) });
How would i write a user who has a role, for example: "kidneys", all the way at the top?
So basically, so it will have more priority.
it might be easier to use a database for something like this.
I am using a simple json file, but i wantt something that is easier to read
as pulling info from the json file is easy to do, but it can be hard to read sometimes.
So i want to export it to txt, with people that have the kidneys role to appear above all the other ones
a database would be easier in both ways.
Not really in my opinion
I am not talking about the programming way of reading
but literally, reading.
For a non-programmer it's really hard to read through all those {}[]
hope that you get what i mean
so youll have to do a few checks, youll need to check the entire file if the user already exists, if so get it and delete it.
then youll probably want to make a temporary file with a copy of the json, or store it in memory, add the user, then add everything else to the original file.
also, just a note, your not using json. you just added .json to the end of a text file, you're still just storing it as text.
this is not my json file.
also note, user tags change, so if this data is important at all, users will lose their data(or youll lose track of it) every time someone changes their tag
Oowh wait i forgott to remove the .json
fs.writeFile("./database.json", JSON.stringify(database), (err) => {
if (err) console.log(err)
});```this is my actual json file
you could store the data as json and then maybe have a command which turns that data from the JSON to a nicer format
also, from a readability perspective non code wise, databases are still imo easier.
can search for stuff, sort stuff on demand, or modify data, much easier.
https://i.woo.pics/844f8b014b.webp
can also format it in an excel style sheet.
I was thinking about for loops, fetching the user ids and eventually checking if they have a role.
I could then easily add them up into a string +=
1
Make it so each route function / data is in a separate file
then fs.readDir + require
Is there a much cleaner way of writing this?
oh
right okay
didn't think of that
cheers
My big brain answering questions before they're asked
death
z = await client.users.cache.get(key)
console.log(z)
if(z.roles.cache.has(role1)){"```
Wait why is there no roles property when using client.users.get
users dont have roles, members do
how would i get the members
fetch?
well i was pretty aware to use the member property
but i used client.members.cache.get(id) before
but it didn't even log
client.members makes no sense.
your bots in multiple guilds, how would the program know what guild to get the member for?
thats why its guild.members
To be fair it does make more sense than putting them in the guild.
but members are always associated with a guild
That would be a good property of the member. A list of guilds they belong to.
I dont think thats feasible unless you have an identify for the user.
it also would probably be a property of users, not members
sorry idk i am having a meltdown in my brain, i used all properties together for some reason
thanks for helping chiefs
I guess it would just be a list of guilds that your bot knows they belong to
well, members are not always cached, so it wouldnt know all of them 90% of the time
I guess that part wouldn't change
But once you fetch the member you could know which guilds they belong to instead of needing to know which guilds they belong to before being able to fetch them.
I just save it to my db for easy access
i had [object Object] on the top.gg site yesterday
At least they translated object into Portuguese.
is Discord actually going to enforce the slash command requirement in April?
i haven't found anything official about it. only hearsay
Well message intent is enforced in April so if you don't have the intent you'll need to use slash commands. That's what people mean by forcing it.
New one
found it If your bot has unique functionality that cannot be replicated or otherwise implemented with interactions, you can begin applying once we open the queue for this intent in fall of 2021.
so they will deny you bot unless it actually needs it
is top.gg going to mass delete bots that dont function after the slash command deadline?
microsoft is an indie company too, remember that %.1f?
no you just wont get the content
And top.gg will be filled with zombie bots
mhmm
Bot reviewers just need to review every bot again. That's not too much work.

It will be quite hard to know if bots are truly dead too, many bots do have downtime.
reviewing all those bots we will be bound to delete still maintained bots off the platform, which is more of a nightmare than just having some dead bots on the platform.
๐ค maybe if discord deletes bots which require message content intents repeatedly while not having access it would be feasable?
but even then i imagine most bots still wouldn't be deleted, just offline
yeah, then even harder to do anything about it
do ya recon my automod bot will get intents
as it needs to check message content for scam urls and possible nuking commands etc
And new slash command bots can be fully functioning, but show as offline.
you dont even need a bot in the server for slash command bots
we have had quite a few of them
i mean its not a bad idea for bots, but its hella annoying
tbh, I dont remember all the things discussed about what will be rejected at the ama. but some pretty big features are rejectable for content intents.
yeah
I imagine youd get it, but its so hard to tell with discord
yeah
how would u prevent nuke commands?
if someone does like .nuke (regular command for nuking), it logs who and then watches incase any mass kicking or banning happens
its still a beta command
but how would it prevent damage?
it would remove admin perms from the bot(s) nuking the server
and then auto reports the user to me so i can blacklist
it also detects mass kicking or banning and if the bot/user kicks and bans 5+ users in 1 minute, it triggers the antinuke
can someone please sanity check me with my code? I'm dealing with a memory leak and I'm looking everywhere to see if I can find any bad memory practices.
Each track played adds a few MB of memory to the stack which is the highWaterMark and does not get swept after the track ends.
https://github.com/AmandaDiscord/Volcano/blob/main/src/worker.ts
doesn't node have a profiler?
Line 78
I've already read through heapdumps. It would be safe for me to post it if you were a masochist and wanted to read it
Naughty naughty

Is that class made more than once?
yup
webstorm has a less-masochist profiler viewer
You should only import the library once
I don't care about type declarations importing libs multiple times
At least that way, TS won't yell at me about something being a variable but being used as a type and then using the typeof keyword and it falls through to the imported member and not referencing a class instance and instead is referencing the Constructor
Import it once at the top and then reference the variable instead of importing again and again.
Like I mentioned, I don't care. It's a style choice and has no effect on code performance
If you don't use typescript then typescript won't yell at you about type issues.
you misunderstood my statement
It's best to avoid classes, constructors, and the this keyword on JS/TS
Try telling that to every JS dev ever. They'll can you a heretic
functional languages exist for a reason and JS is not functional
js is multi-paradigm, just pick what you like best
I finnly applied lets hope my bot gets aproved!!!
what does "dockerize" means
Put something into docker
what's docker 
Docker makes your entire project portable and containerized.
It makes it easy to just run things on another server in a few minutes.
Pretty much it installs everything you need for a project with a few commands and runs it in its own enviroment
Tbh I haven't really used docker at all, but thats my understanding of the use case.
How would I remove guild custom slash commands from a guild?
Without kicking the bot*
what library r u using?
DELETE discord.com/api/v8/applications/<my_application_id>/guilds/<guild_id>/commands/<command_id>
with header Authorization: Bot BOT_TOKEN
why v8?
i thought the latest one was v9
lel
I am receiving undefined with "vote.user" and an empty array with "vote", why?
I'm trying to have a bot create a support ticket if the ID of the button is support. However, whenever I click the Support button it says, "Interaction failed."
Code:
client.on('interactionCreate', async interaction => {
if (interaction.isButton()) {
const filter = i => i.customId === 'support';
const collector = interaction.channel.createMessageComponentCollector({ filter, time: 5000 });
collector.on('collect', async i => {
if (i.customId === 'support') {
await i.update({ content: 'A button was clicked!', components: [] });
}
});
collector.on('end', collected => console.log(`Collected ${collected.size} items`));
}
});
my bot is finished.. am i missing any features, errors or ideas? A demonstration of this bot is located here:
https://pastebin.com/smn0ZJfG if anyone could check the gifs out and lmk id appreciate it!
Pastebin.com is the number one paste tool since 2002. Pastebin is a website where you can store text online for a set period of time.
U didn't acknowledge it
Wdym?
Literally that, u need to either deferReply or deferEdit
U have only 3 seconds for that
Pretty sure there's no "vote.user"
hi i just wanna host my bot 24/7 for free , no heroku , no repl it what do i do?
dm me
k
if they ask here, there's gonna be people like me who'll yell at them instead of helping 
Not possible
Use repl.it
Best one yet
And use uptimerobot
To keep your project online. 24/7
kk
free plan vps requires your credit card
most coders here are students who don't have permission to hodl a credit card
True
question: I'm making a link filter to delete messages that contain links except if it only contains links from trusted sources like tenor, giphy and discord cdn
my question: how many discord cdn links are there
they can ask their parents
.discord(app)?.(com|net)
should i use this


Lul
Just accept any subdomain of discord
yeah
links.filter(x => !/(\b.+?\.discord(app)?\.(com|net)\b)/i.test(x));
htttps://test.com/?discord.com

oof
links.filter(x => !/https?:\/\/(.+?\.)?discord(app)?\.(com|net)/ig.test(x));
@proven lantern
also parse it with a url parser and pull out the hostname
i should do that probably
// change const links to let links
links = links.filter(link => {
const url = new URL(link);
if (["com", "net"].some(x => x === url.tld.toLowerCase()) && ["discord", "discordapp", "tenor", "giphy"].some(x => x === url.hostname.toLowerCase())) return false;
return true;
});
discord.finance goes through the check
if (links.length) {
// HELLA SUS LINK
}
dont do it
i need the scam links later so ยฏ_(ใ)_/ยฏ
do the filter thing twice

make your variable name make sense
const scamLinks = allLinks.filer(...)
const goodLinks = allLinks.filer(...)
allLinks will always contain allLinks
why do you hate mutation
because the variable name doesn't change
const aThingThatWillBeAnotherThingLater;
ah
i see, you're trying to explain the importance of types
const resp = await fetch("never gonna give you up");
resp = await resp.json();
console.log(resp.status); // undefined
const resp: Response = await fetch("never gonna give you up");
const json: object = await resp.json();
console.log(resp.status); // 420
types dont solve much
finally someone said that
well i don't really care about mutating unless i'm using state in react components
"discord.com":true
}
const goodLinks = links.filter(link=> goodHostnames[new URL(link).hostname]);
const badLinks = links.filter(link=> !goodHostnames[new URL(link).hostname]);
id do this
exams from?
ending on 24th
starting on 28th
oof
two days before halloween
yes
Is possible to make a command for.my bot that auto votes my bot from other users? Like !topggvote or some shit
I'd use a single for loop tbh
I dont think so
Damn
yes
How can i fix that ?
what was the syntax to console log many times?
wasn't there a way to do it just like
console.log("Print this 10 times") x 10?
Whatever you were trying to do either wasnโt allowed or your bot doesnโt have the permission to do it
Also if it was a command that delete messages in a huge chunk at once. I think it goes against tos
Can this change a value of a property?
'use-strict'; // Strict JS File
require('dotenv').config(); // Requiring the ".env" file to access the passwords that will allow us to use to be able to fetch from the Dictionary API.
const settings = require('../settings/settings.js');
(async () => {
settings.find(val => val.id.toLowerCase() === "translationlanguage").language = 'arabic';
})();
module.exports = [
{
id: 'translationlanguage',
description: 'Please mention the translation language you want to tralsnate your word to.',
language: 'Arabic'
},
];
@feral aspen no
What can I do instead?
๐
then when you need languages just use the name as a variable
Sweet.. sure.
Can I configure it later?
.. to be actually changed in the code, too?
change the value of the global.languages variable
// remember to use the word global. when changing its value
const msg = await message.reply({ embeds: [embed], components: [row, row2] })
const collector = msg.createMessageComponentCollector({ time: 120000, errors: ['time'] })
when i delete the msg it send this err
DiscordAPIError: Unknown Message
at RequestHandler.execute (E:\C) Developing\Wolfy Djs-13\node_modules\discord.js\src\rest\RequestHandler.js:298:13)
at processTicksAndRejections (node:internal/process/task_queues:96:5)
at async RequestHandler.push (E:\C) Developing\Wolfy Djs-13\node_modules\discord.js\src\rest\RequestHandler.js:50:14)
at async MessageManager.edit (E:\C) Developing\Wolfy Djs-13\node_modules\discord.js\src\managers\MessageManager.js:131:15) {
method: 'patch',
path: '/channels/876309321468743780/messages/890181879163129876',
code: 10008,
httpStatus: 404,
requestData: {
json: {
content: undefined,
tts: false,
nonce: undefined,
embeds: [
{
title: null,
type: 'rich',
description: null,
url: null,
timestamp: 0,
color: null,
fields: [],
thumbnail: null,
image: null,
author: {
name: 'WOLF#1045',
url: undefined,
icon_url: 'https://cdn.discordapp.com/avatars/724580315481243668/51ee6aa3632cf80d6c33ed907bf0c52b.webp?size=2048'
},
footer: null
}
],
components: [
{
components: [ [Object], [Object], [Object], [Object], [Object] ],
type: 1
},
{ components: [ [Object], [Object] ], type: 1 }
],
username: undefined,
avatar_url: undefined,
allowed_mentions: undefined,
flags: 0,
message_reference: undefined,
attachments: undefined,
sticker_ids: undefined
},
files: []
}
No it's only deleting 100 messages and set a cooldown for message author
try less than a 100 and see what happens, if it comes up with the same thing, then it's a permission error
try like 10 to expirement
100 Didn't log error
wait why are you using message and msg
your command handler only uses one or the other
It's another code
Heyoo.. if you go to your Microsoft Store and search for Terminal, does anyone know a website that I can use that does the same thing in that application's background video
that should work
Doesn't, though. :((
wait, what exactly do you expect to happen?
you use &&
u wanna check if they are not someone and not the other
@earnest phoenix
I want to change the property of an object in another file, and it changes the code there too.
Like fs.
oh yeah that won't work.
you have to use fs
Can that edit JS files, too?
it can edit any file
Sweet.
but why would you want to do that...
bot settings or guild settings?
Where to be able to input values via the terminal.
Using a JS file is kind-of easy for me, honestly, in addition that I am sending the files I am making to some teenagers to use and read and identify what it does.
im thinking of making a react component lib for bot dashboards
Using js files is definitely not easier, but you do you
ssd or hdd?
SDD/
Solid disk drive
No
so you have an ssd or a regular hd?
SSD
My pc just shutted down.
It has an SSD that I have used 30% of.
.. and my frames in MC went from 800 to 12.
so its only MC that is slow?
The whole computer.
what else is slow?
Everything.
how long does it take to start windows?
It was 10 seconds now a minute.
have you checked task manager?
and disk %?
did your windows update recently?
Updated now.
All up to date.
I have 5 hard disks.
Wait..
My bad
1 ssd 2 had and 2 usbs
Hdd
whats the disk usage of the other ones?
0
check for bad sectors in the hdds
and check which processes are starting on startup
It just became slow today.
still
which one
windows def is always default
so only windows defender?
Yes
show your startup tab in your task manager
cant you use print screen lol
I don't see any sus process
check for hdd bad sectors
HowM
sometimes it makes the computer slow bcuz it's trying to read it constantly
but that would cause high disk usage usually
No errors.
try running in safe mode
Becoming "slow" is relative. Can you measure the speed of the drive, please?
they said booting went from 10 secs to 1 minute
Yes.
winsat disk -ran -read -drive C (read) where C is the drive to measure
winsat disk -ran -write -drive C (write)
Run those two in your command prompt please.
(as administrator)
try this too
And post the results (readable)
right click -> properties -> tools -> verify
It opens a new window then closes.
huh, no it doesn't open a new console prompt
It does.
> Running: Feature Enumeration ''
> Run Time 00:00:00.00
> Running: Storage Assessment '-ran -read -drive C'
> Run Time 00:00:00.31
> Dshow Video Encode Time 0.00000 s
> Dshow Video Decode Time 0.00000 s
> Media Foundation Decode Time 0.00000 s
> Disk Random 16.0 Read 843.09 MB/s 8.6
> Total Run Time 00:00:00.47
> Running: Feature Enumeration ''
> Run Time 00:00:00.00
> Running: Storage Assessment '-ran -write -drive C'
> Run Time 00:00:00.55
> Dshow Video Encode Time 0.00000 s
> Dshow Video Decode Time 0.00000 s
> Media Foundation Decode Time 0.00000 s
> Disk Random 16.0 Write 243.00 MB/s
> Total Run Time 00:00:00.80
Hmm okay, so the drive still works well, might really be an defragmentation issue, corrupt data or something is running in the background you're not aware of
defrag in ssd?
I did launch MC once and not all of my worlds loaded up.
Didn't you say it's a HDD?
he has 1 ssd and 2 hdd
Oh my bad
btw, do u keep games in ssd or hdd?
I keep MC only in ssd, rest in HDD
https://codepen.io/tyrone5693/pen/BaZPaRq
Can someone help me
It shows only signup thing it have to show home about services
use verify tool to see if there's some detectable issue
Is the drive you tested the drive Windows is running on?
it usually solves stuff
Wdym?
winsat disk -ran -read -drive C (read) where C is the drive to measure
what?
for me it's fine
Oh, yes.
Did you run the command as I wrote (C drive)
Try on mobile
Yes, I did.
not on mobile, can't
did u write that or is it some bootstrap thing?
Do I defragment?
items.forEach(x => { ๐
Iy worked
unless u wanna stay the whole day there...no
also ssds dont need to be defragged
use verify tool
on all drives
i'd reboot into safe mode and check if the slowness still exists there
and yeah, running chkdsk /f on all drives is also a good idea
The type of the file system is NTFS.
Cannot lock current drive.
Chkdsk cannot run because the volume is in use by another
process. Would you like to schedule this volume to be
checked the next time the system restarts? (Y/N)
admin, always run as admin
it has to run during boot time, since it cant run with the os running on it
Oh..
Y then restart
i'd reboot into safe mode and check if the slowness still exists there
That seems to be best tip for your situation tho.
also, do you usually install the optional windows updates?
more specifically the driver updates
alright.. I've decided to restart my pc.. if the slowness yet there.. then I'm checking in boot mode.
Currently restarting.
Press your Windows key to open the startmenu, enter msconfig and hit enter, select diagnostic start and see if the issue persits.
Its fixing.. tf
๐
ssd is not fair
Still slowly?
Same command?
Do I just run chkdsk again and again for all drives and then restart?
I only access my VPS as Root, but I know if someone manages to get my IP and password I'm f'd.
Any tips on securing access?
u dont need to restart for non-windows drives
ssh keys
No errors.
ah yes, it done
First of all, disable external root access, add an user and grant him sudo permissions
do it for remaining drives too
Second thing is what Tim told you
I have ssh on my machines
but you said you use a login password?
ssh keys are a replacement for login password
thats not what im talking about
I know
an ssh key is a file that you use instead of a password
I have that for git
Did so.
Nothing.. no further action needed.
still slow?
Yes. ๐
gonna set up a user
First of all, disable external root access, add an user and grant him sudo permissions
reboot into safe mode with network
Most important thing, still
I will.
yes
Must be disabled in the SSH conf
Pfff nooooooooooooob
what's the difference between root and user + sudo?
everyone knows root's login username
idk why
you have a point
Ok Sir, you're now offically on the blacklist!

Safe boot with network.. right?
yes
what they doin'?
Please try to take photos N O T from a 120ยฐ angle
and not ultra-high-res
too bad, that's actually 119.5ยฐ
pleb


I see you're looking for trouble since you're on the blacklist 
I'm in boot mode.. now?
blacklisted people get blackmailed
Any noticable changes?
did windows already load? or are you in the advanced boot menu?
well, 180 angle with a 45 turn
and see if its still slow
cool
Of course it is, only system relates services are loaded
so now answer my previous question: do you usually install the optional windows updates? more specifically the driver updates?
ok, so next time, dont
optional updates are usually "if we fucked ur pc in the last update, try installing one of those"
windows drivers are not always 100% compatible with your specific hardware
Basically us as donkeys.
I see.
since they are made to be compatible with a lot of things
Nothing we can say for sure but it can also be something running in the background, still
you should only install drivers from the manufacturer
you have to revert/uninstall them
does windows update have a way to revert driver updates?
You can disable to include driver updates via. Windows update at all
try checking the update history
Now.. let me go back to normal mode.. do I use normal startup and disable safe boot?
zone management is useless if I don't pay for a domain so...
then yeah disable safe boot and restart
Normal startup too.. right?
After starting Windows, disable driver updates via. Windows update entirly
Hit Windows key to open the startmenu, enter gpedit.msc and hit enter, use the left navbar to navigate toComputer config > Administrative ... > Windows components > Windows Update
Take a look into the list, there should be something like Do not include drivers via. Windows update, double click it, change the value to activate
that took a while 
Or enable yeah
Will be active after a restart, do not forget about removing optional driver updates
check driver updates section and see which drivers were more recently installed, anything that was installed right before the slowness started?
Where exactly.
MVM
Nope..
And make sure to (re)install hardware drivers of your manufactor, at least all required drivers you can download after checking your mainboard manufactor driver websites...
I cant uninstall the 24 driver updates.
not uninstall
Then?
just check the date installed
and which one is it?
The monitor
everything else is older?
hmm then this is likely not a driver issue
i mean, it can still be, if a driver broke for some reason
Let's check your services
Start msconfig again, select Services, check Do not include Microsoft services and take a screenshot of the whole list
Hmm unfortunately this doesn't look suspicious, too
๐
Only thing you can try not mus try, is to hit disable all and reboot
If there's still no difference keep in mind to enable all again
(after the reboot)
why is this not being read as json but a pure string?
how did you read it?
not easytune
GIGABYTE adjust
all other gigabyte-related services in that list are listed under GIGA-BYTE TECHNOLOGY
except that one
manufacturers dont always make good software, many times they make shitty mistakes like that, i've seen it before
Let's see what he says after disabling all
I had to parse it ๐
you can also read json files with require
So you're using fs then to read the file?
fs always reads raw data, without any parsing
Didnt work...
not a service issue then
No noticable difference?
Alr
I smell Tim's malware
...first re-enable the services btw
aka. Timware
Renabled.
order processes by page faults and show it
Didnt understand this.
212 million faults holy
well, its been running for weeks
wth
Wait.. a new one popped up.. software_reporter_tool.exe
its ungoogled chromium, not chrome
What now?
hmm, software reporter tool has been known for a while to cause problems
Alright, damn thought I got you...
but that wouldnt explain windows being slow when chrome is closed
๐
is your computer still slow if you close chrome and discord?
Yes
does closing chrome close everything about chrome?
or are there background chrome processes left?
All closed
including software reporter?
Also close the mentioned ones
so software reporter is still running?
Right click

did you ever run driver verifier?
Yes I did
when did you run it?
When you asked me to?
i didnt ask about driver verifier?
OH
i mean verifier.exe
when did you run it?
Not verified but application verifier
delete existing settings
No settings were changed.
Hey guys, where are you from ?
then that wasnt the issue
Still belive something is writing/reading the disk continuesly
but the disk is reporting no activity?
Oh isn't it
?
ye
nvm then
probably wont help much, but try installing malwarebytes and running a scan
Its yet really slow. ๐
another thing you can try is running sfc /scannow
Installing malwarebyte.
Might also be a good idea to check the smart values for your drive
How?
There's no Windows built in way, sadly
you can use a tool like hddscan
But CrystalDiskInfo is a good tool
Tim trying to sell his software
Malwarebytes is scanning.




