Empresas
Empleos
  • Sobre nosotros
  • Soluciones
    • Publicación de vacantes
      Publica tu vacante y recibe candidatos calificados en 48h.
    • Evaluación de candidatos
      500+ pruebas técnicas y psicológicas, más anti-fraude.
    • Headhunting
      Búsqueda ejecutiva a la medida de principio a fin.
    • Nómina + EOR
      Dispersión de nómina y EOR en más de 15 países de LATAM.
  • Precios
  • Empleos

0

150
Vistas
message.channel.awaitmessages() filter not working with constant id

I have this command that is supposed to only accept user inputs from me. I am trying to use this code but there is nothing in the console.

me = await client.users.fetch("< my id >")
mee = msg
mee.author = me
let filter = m => m.author.id === mee.author.id
msg.channel.awaitMessages(filter, { max: 1, time: 50000, errors: 
   ['time'], })
      .then(async (collected) => {
      mesg = collected.first
      console.log(mesg.content)
   })
about 4 years ago · Juan Pablo Isaza
1 Respuestas
Responde la pregunta

0

There's really no reason to be fetching a user if the only thing you need is their ID - which you're already using for the fetch itself.

What you're currently trying to do - overriding the author of an existing message - doesn't really make much sense.

Your filter can (likely) be simplified down to the following.

let filter = m => m.author.id === "<your id>"
about 4 years ago · Juan Pablo Isaza Denunciar
Responde la pregunta
Encuentra empleos remotos

¡Descubre la nueva forma de encontrar empleo!

Top de empleos
Top categorías de empleo
Empresas
Publicar vacante Precios Comercial
Legal
Términos y condiciones Política de privacidad
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomiéndame algunas ofertas
Necesito ayuda