Skip to content

Commit 27538aa

Browse files
committed
Merge branch '6.3' into 6.4
* 6.3: #19510 in symfony 6.3 there was no Schedule::with(...), but Schedule::add(...)
2 parents fdd2362 + b618b53 commit 27538aa

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

scheduler.rst

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -354,7 +354,7 @@ Finally, the recurring messages has to be attached to a schedule::
354354
public function getSchedule(): Schedule
355355
{
356356
return $this->schedule ??= (new Schedule())
357-
->with(
357+
->add(
358358
RecurringMessage::trigger(
359359
new ExcludeHolidaysTrigger(
360360
CronExpressionTrigger::fromSpec('@daily'),
@@ -859,7 +859,7 @@ This allows the system to retain the state of the schedule, ensuring that when a
859859
$this->removeOldReports = RecurringMessage::cron('3 8 * * 1', new CleanUpOldSalesReport());
860860

861861
return $this->schedule ??= (new Schedule())
862-
->with(
862+
->add(
863863
// ...
864864
)
865865
->stateful($this->cache)
@@ -881,7 +881,7 @@ same task more than once::
881881
$this->removeOldReports = RecurringMessage::cron('3 8 * * 1', new CleanUpOldSalesReport());
882882

883883
return $this->schedule ??= (new Schedule())
884-
->with(
884+
->add(
885885
// ...
886886
)
887887
->lock($this->lockFactory->createLock('my-lock')
@@ -908,7 +908,7 @@ before being further redispatched to its corresponding handler::
908908
public function getSchedule(): Schedule
909909
{
910910
return $this->schedule ??= (new Schedule())
911-
->with(
911+
->add(
912912
RecurringMessage::every('5 seconds'),
913913
new RedispatchMessage(new Message(), 'async')
914914
);

0 commit comments

Comments
 (0)