BlueBubblesApp / bluebubbles-server

Server for forwarding iMessages to clients within the BlueBubbles App ecosystem

Home Page:https://bluebubbles.app

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Schedule sent messages immediately send instead of waiting 4 weeks into the future.

jjrocks opened this issue · comments

Steps to Reproduce

  1. Open up schedule send on any client (I tried on Windows and on Android)
  2. Type any message.
  3. Schedule a message for 4 weeks into the future
  4. Press send

Expected

It shouldn't send a message to the user

Observed

It does send a message.

Light clarification from a bad title. For an example let's day today is Feb 27, 2024 and I schedule a message for Feb 29, 2024. It'll successfully wait until the 29th to send the message. However if I were to send a message on March 26th instead of Blue Bubbles waiting until March 26th, it will send it as soon as I schedule it (on Feb 27th)

I have tried a few other things:

  • It successfully waits to send the message up to 3 weeks in advance
  • This happens with two separate people I've tried

Also just so people know
Server version: 1.9.5
Android App version:1.12.7

Light clarification from a bad title. For an example let's day today is Feb 27, 2024 and I schedule a message for Feb 29, 2024. It'll successfully wait until the 29th to send the message. However if I were to send a message on March 26th instead of Blue Bubbles waiting until March 26th, it will send it as soon as I schedule it (on Feb 27th)

I have tried a few other things:

  • It successfully waits to send the message up to 3 weeks in advance
  • This happens with two separate people I've tried

Also just so people know Server version: 1.9.5 Android App version:1.12.7

I've reproduced it as well, thank you. However, moving this to the server repo as the server is what handles the scheduling.

Fixed this on my development branch. The issue was that setTimeout only allows a delay value of up to the max 32 bit integer (2,147,483,647), which is about 24 days. Scheduling a message for > that value will default back to 1. Which is why we saw the message immediately send.