Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Create reminder #119

Merged
merged 15 commits into from Oct 16, 2019
Merged

Conversation

blimyj
Copy link

@blimyj blimyj commented Oct 16, 2019

No description provided.

Copy link
Collaborator

@Icesiolz Icesiolz left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

//TODO: Check if Optional is present before .get()
reminder = reminders.get(0).getReminder().get();
synchronized (reminders) {
while (reminder != null && reminder.getDateTime().isBefore(LocalDateTime.now())) {

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great work! Just wondering, how do you handle the case where the reminder is before the LocalDateTime? Does it inform the user?

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sorry, could you clarify what you mean? The code above handles the case where the reminder is before the LocalDateTime.now(). On the off-chance you meant to ask if the reminder is after LocalDateTime.now() then it should remain in reminders list as the loop continues to check for reminders that are due to show.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants