| Conditions | 1 |
| Paths | 1 |
| Total Lines | 14 |
| Code Lines | 8 |
| Lines | 0 |
| Ratio | 0 % |
| Tests | 0 |
| CRAP Score | 2 |
| Changes | 2 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php |
||
| 40 | public function addCron(Request $request) |
||
| 41 | { |
||
| 42 | $cronExpression = $request->request->get('expression'); |
||
| 43 | $cronId = $request->request->get('cronId'); |
||
| 44 | |||
| 45 | $event = new CronEvent( |
||
| 46 | new TimingEvent($cronId), |
||
| 47 | $cronExpression |
||
| 48 | ); |
||
| 49 | |||
| 50 | $this->dispatcher->dispatchEvent($event); |
||
| 51 | |||
| 52 | return true; |
||
| 53 | } |
||
| 54 | } |
||
| 55 |