Fix log create disable
This commit is contained in:
parent
6d646394fc
commit
9685d75ad4
4
index.js
4
index.js
|
@ -251,7 +251,9 @@ client.on('interactionCreate', async interaction => {
|
|||
});
|
||||
return;
|
||||
}
|
||||
const log_create = interaction.options.getBoolean('log_create') || true;
|
||||
log_create = interaction.options.getBoolean('log_create');
|
||||
if (log_create == null) log_create = true;
|
||||
console.log(log_create)
|
||||
const channel = interaction.options.getChannel('channel').id;
|
||||
db.run(`INSERT OR REPLACE INTO guilds (id, channel, log_create) VALUES (?, ?, ?)`, [interaction.guild.id.toString(), channel.toString(), log_create], (err) => {
|
||||
if (err) {
|
||||
|
|
Loading…
Reference in a new issue