Empresas
Empregos
  • Sobre nós
  • Soluções
    • Publicação de vagas
      Publique sua vaga e receba candidatos qualificados em 48h.
    • Avaliações de candidatos
      Mais de 500 testes técnicos e psicológicos, mais anti-fraude.
    • Headhunting
      Busca executiva personalizada do início ao fim.
    • Folha de Pagamento + EOR
      Dispersão de folha e EOR em mais de 15 países da LATAM.
  • Preços
  • Empregos

0

144
Visualizações
Problem with the function update of cron-job-manager

I'm using the lib cron-job-manager to manage my cron because i'm running multiple crons in my app but i have an issue when i want to update the specific cron i do it like this:

manager.update(alertData.id.toString(), cronFinal)

But it's not working when i see the function it take this as arguments:

update(...args: any): void

The documentation says

You may want to change the task, time or both of any job during execution. You can do so using the update function

manager.update('key', '0 15 3,5,9,14,18,20 * * *', () => {// do this instead on this new schedule
});
manager.update('key', () => { // do this instead 
});
manager.update('key', '0 15 3,5,9,14,18,20 * * *') // do it on this schedule instead.

The error i have is this one;

error updating tab: 33 - Cannot read property 'running' of undefined

33 corresponding to the id.toString() i'm using

Can someone tell me what i am doing wrong pls ?

Thanks by advance :D

about 4 years ago · Juan Pablo Isaza
Responde à pergunta
Encontrar trabalhos remotos

Descubra a nova forma de encontrar um emprego!

melhores empregos
Principais categorias de trabalho
Empresas
Postar vaga Preços Comercial
Jurídico
Termos e Condições Política de privacidade
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomende algumas ofertas para mim
Preciso de ajuda