| Conditions | 2 |
| Paths | 2 |
| Total Lines | 10 |
| Code Lines | 7 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 0 | ||
| 1 | <?php |
||
| 27 | public function __construct(string $message) |
||
| 28 | { |
||
| 29 | $this->handled = false; |
||
| 30 | $this->rawMessage = $message; |
||
| 31 | |||
| 32 | if (preg_match('/^(?::(?<source>[^\s]+)\s*)?(?<command>[^\s]+)\s*(?<commandsuffix>[^:$]+)?\s*(?::(?<payload>.*?))?$/', $message, $matches)) { |
||
| 33 | $this->source = $matches['source'] ?? null; |
||
| 34 | $this->command = $matches['command'] ?? null; |
||
| 35 | $this->commandsuffix = trim($matches['commandsuffix'] ?? null); |
||
| 36 | $this->payload = $matches['payload'] ?? null; |
||
| 37 | } |
||
| 54 |
This check looks for parameters that have been defined for a function or method, but which are not used in the method body.