| Total Complexity | 2 |
| Total Lines | 30 |
| Duplicated Lines | 0 % |
| Changes | 1 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php |
||
| 9 | class DbLogListener |
||
| 10 | { |
||
| 11 | /** |
||
| 12 | * Handle the event. |
||
| 13 | * |
||
| 14 | * @param object $event |
||
| 15 | * |
||
| 16 | * @return void |
||
| 17 | */ |
||
| 18 | public function handle(SmsEvent $event): void |
||
| 19 | { |
||
| 20 | $this->saveLogInDb($event->smsDriver); |
||
|
|
|||
| 21 | } |
||
| 22 | |||
| 23 | /** |
||
| 24 | * This method should call in all driver send method in last line. |
||
| 25 | * |
||
| 26 | * @return void |
||
| 27 | */ |
||
| 28 | protected function saveLogInDb(Driver $smsDriver): void |
||
| 39 | } |
||
| 40 | } |
||
| 41 |