| Conditions | 3 |
| Paths | 3 |
| Total Lines | 9 |
| Code Lines | 5 |
| Lines | 0 |
| Ratio | 0 % |
| Tests | 6 |
| CRAP Score | 3 |
| Changes | 1 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php |
||
| 24 | 4 | public static function registerMailer($class) |
|
| 25 | { |
||
| 26 | 4 | if (!in_array(MailWrapperInterface::class, class_implements($class))) { |
|
| 27 | 1 | throw new InvalidMailHandlerException('Class not implements ConnectorInterface!'); |
|
| 28 | } |
||
| 29 | |||
| 30 | 3 | $protocolList = $class::schema(); |
|
| 31 | 3 | foreach ((array)$protocolList as $item) { |
|
| 32 | 3 | self::$config[$item] = $class; |
|
| 33 | } |
||
| 55 |