Bugfix: Don't say we're late if we aren't
This commit is contained in:
parent
3d4af3eb2f
commit
3b072f3e97
1 changed files with 2 additions and 2 deletions
|
@ -345,7 +345,7 @@ namespace RhinoReminds
|
||||||
while (true) {
|
while (true) {
|
||||||
nextReminder = reminderList.GetNextReminder();
|
nextReminder = reminderList.GetNextReminder();
|
||||||
// Wait for the next reminder
|
// Wait for the next reminder
|
||||||
TimeSpan nextWaitingTime;
|
TimeSpan nextWaitingTime = new TimeSpan();
|
||||||
try {
|
try {
|
||||||
if (nextReminder != null) {
|
if (nextReminder != null) {
|
||||||
nextWaitingTime = nextReminder.Time - DateTime.Now;
|
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!
|
Jid targetJid = nextReminder.Jid; // Apparently nextReminder is null after the sendAndDeleteReminder() call - very odd!
|
||||||
sendAndDeleteReminder(nextReminder);
|
sendAndDeleteReminder(nextReminder);
|
||||||
|
|
||||||
if (nextWaitingTime.TotalMilliseconds < -1) {
|
if (nextWaitingTime.TotalMilliseconds < -1 * 2000) {
|
||||||
client.SendChatMessage(
|
client.SendChatMessage(
|
||||||
targetJid,
|
targetJid,
|
||||||
"(Sorry I'm late reminding you! I might not have been running at the time, " +
|
"(Sorry I'm late reminding you! I might not have been running at the time, " +
|
||||||
|
|
Loading…
Reference in a new issue