Bugfix: Don't say we're late if we aren't

master
Starbeamrainbowlabs 4 years ago
parent 3d4af3eb2f
commit 3b072f3e97
Signed by: sbrl
GPG Key ID: 1BE5172E637709C2
  1. 4
      RhinoReminds/ClientListener.cs

@ -345,7 +345,7 @@ namespace RhinoReminds
while (true) {
nextReminder = reminderList.GetNextReminder();
// Wait for the next reminder
TimeSpan nextWaitingTime;
TimeSpan nextWaitingTime = new TimeSpan();
try {
if (nextReminder != null) {
nextWaitingTime = nextReminder.Time - DateTime.Now;
@ -383,7 +383,7 @@ namespace RhinoReminds
Jid targetJid = nextReminder.Jid; // Apparently nextReminder is null after the sendAndDeleteReminder() call - very odd!
sendAndDeleteReminder(nextReminder);
if (nextWaitingTime.TotalMilliseconds < -1) {
if (nextWaitingTime.TotalMilliseconds < -1 * 2000) {
client.SendChatMessage(
targetJid,
"(Sorry I'm late reminding you! I might not have been running at the time, " +

Loading…
Cancel
Save