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

fix: calculate afterConstrain diff in minutes #2581

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

badcristian
Copy link

fixes #2575

this was used on line 47:
$schedule->timestamp_target->diffInMinutes(now()->floorSeconds()) >= $schedule->delay_minutes

instead of this:
$schedule->timestamp_target->diffInMinutes(now()->floorSeconds()) === $schedule->delay_minutes

because the second option will work only if mailator will be run every minute, which will probably not happen. So, for example, if the notification should be sent 10m after a target time and when the mailator is run we are more than 20m past it i think this should return true anyway.

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.

In After Constraint, minutes frequency not working.
1 participant