-
-
Notifications
You must be signed in to change notification settings - Fork 92
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
Schedule broken in Develop branch #1395
Comments
I've found why it worked for myself, and now doesn't in the For Schedules/Tasks the This means if you want to use the event object, you need a parameter explicitly called Add-PodeSchedule -Name 'predefined' -Cron '@minutely' -Limit 2 -ScriptBlock {
param($Event, $Message1, $Message2)
$using:message | Out-Default
Get-PodeSchedule -Name 'predefined' | Out-Default
"Last: $($Event.Sender.LastTriggerTime)" | Out-Default
"Next: $($Event.Sender.NextTriggerTime)" | Out-Default
"Message1: $($Message1)" | Out-Default
"Message2: $($Message2)" | Out-Default
} It seems to stem from #1333, and one we missed, but in there the parameter name was changed: Add-PodeSchedule -Name 'predefined' -Cron '@minutely' -Limit 2 -ScriptBlock {
param($TriggeredEvent, $Message1, $Message2)
$using:message | Out-Default
Get-PodeSchedule -Name 'predefined' | Out-Default
"Last: $($TriggeredEvent.Sender.LastTriggerTime)" | Out-Default
"Next: $($TriggeredEvent.Sender.NextTriggerTime)" | Out-Default
"Message1: $($Message1)" | Out-Default
"Message2: $($Message2)" | Out-Default
} Changing I can fix it, though not sure on how to get a test in there for it. I'll have a think. |
I can fix it here |
Fixed in #1384 |
Describe the Bug
The last Pull #1393 has broken the Pode Schedule
Steps To Reproduce
run the
examples\Schedule.ps1
Expected Behavior
Actual Behavior
The text was updated successfully, but these errors were encountered: