| Conditions | 3 |
| Paths | 3 |
| Total Lines | 10 |
| Code Lines | 6 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 0 | ||
| 1 | <?php |
||
| 46 | public function getMutex() |
||
| 47 | { |
||
| 48 | if ($this->storageFactory instanceof MemcachedFactory) { |
||
| 49 | return new MemcachedMutex($this->storageFactory->create()); |
||
| 50 | } elseif ($this->storageFactory instanceof RedisFactory) { |
||
| 51 | return new RedisMutex($this->storageFactory->create()); |
||
| 52 | } |
||
| 53 | |||
| 54 | throw new \RuntimeException(sprintf('Mutex storage of type "%s" is not supported.', gettype($this->storageFactory))); |
||
| 55 | } |
||
| 56 | } |
||
| 57 |
Our type inference engine has found an assignment to a property that is incompatible with the declared type of that property.
Either this assignment is in error or the assigned type should be added to the documentation/type hint for that property..