Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

231
Views
How to create an id array in quick.db Discord.js

I'm trying to make a local black list of members. But I ran into a problem that the bot does not create an array, but inserts only one value

const db = require("quick.db")
module.exports.run = async (discord, bot, message, args, p) => {
    db.push(`black_${message.guild.id}`, args[0])
    const bl = db.get(`black_${message.guild.id}`)
    message.channel.send(`${bl}`)
}
module.exports.help = {
    name: 'black',
    aliases: [''],
    description: ''
}

Is there any other way to create an array for each server?

about 4 years ago · Juan Pablo Isaza
1 answers
Answer question

0

Using await and different constructor might fix your issue.

const { QuickDB } = require("quick.db");
const db = QuickDB();

module.exports.run = async (discord, bot, message, args, p) => {
    await db.push(`black_${message.guild.id}`, args[0])
    const bl = await db.get(`black_${message.guild.id}`)
    message.channel.send(`${bl}`)
}
module.exports.help = {
    name: 'black',
    aliases: [''],
    description: ''
}
about 4 years ago · Juan Pablo Isaza Report
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!