mirror of
https://github.com/arthur-pbty/bot-discord-coins.git
synced 2026-06-22 18:19:25 +02:00
Add guildName et userName (pour facilité la lecture de la bd)
This commit is contained in:
@@ -6,7 +6,7 @@ module.exports = {
|
||||
async execute(guild) {
|
||||
db.run(`INSERT OR IGNORE INTO config (guildId, name, value) VALUES (?, ?, ?)`, [guild.id, 'prefix', '&']);
|
||||
guild.members.cache.forEach(member => {
|
||||
db.run(`INSERT OR IGNORE INTO users (guildId, userId) VALUES (?, ?)`, [guild.id, member.id]);
|
||||
db.run(`INSERT OR IGNORE INTO users (guildId, guildName, userId, userName) VALUES (?, ?)`, [guild.id, guild.name, member.id, member.name]);
|
||||
});
|
||||
},
|
||||
};
|
||||
Reference in New Issue
Block a user