| Conditions | 3 |
| Paths | 3 |
| Total Lines | 12 |
| Code Lines | 6 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 1 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php |
||
| 32 | public function __construct($uri, $encoding = null, $options = 0) |
||
| 33 | { |
||
| 34 | if (!is_readable($uri)) { |
||
| 35 | throw new InvalidArgumentException(sprintf('Invalid URI: %s', $uri)); |
||
| 36 | } |
||
| 37 | |||
| 38 | $result = $this->open($uri, $encoding, $options); |
||
| 39 | |||
| 40 | if ($result !== true) { |
||
| 41 | throw new RuntimeException(sprintf('Could not open %s', $uri)); |
||
| 42 | } |
||
| 43 | } |
||
| 44 | |||
| 64 | } |
This check looks for a call to a parent method whose name is different than the method from which it is called.
Consider the following code:
The
getFirstName()method in theSoncalls the wrong method in the parent class.